Search Results for

    Show / Hide Table of Contents
    View Source

    Interface IDefaultViewContentProvider

    Provides default content for Razor view files.

    Namespace: Umbraco.Cms.Core.IO
    Assembly: Umbraco.Core.dll
    Syntax
    public interface IDefaultViewContentProvider

    Methods

    View Source

    GetDefaultFileContent(string?, string?, string?, string?)

    Gets the default file content for a Razor view.

    Declaration
    string GetDefaultFileContent(string? layoutPageAlias = null, string? modelClassName = null, string? modelNamespace = null, string? modelNamespaceAlias = null)
    Parameters
    Type Name Description
    string layoutPageAlias

    The optional alias of the layout page to inherit from.

    string modelClassName

    The optional class name of the model.

    string modelNamespace

    The optional namespace of the model.

    string modelNamespaceAlias

    The optional alias for the model namespace (defaults to "ContentModels").

    Returns
    Type Description
    string

    The default Razor view content as a string.

    • View Source
    In this article
    Back to top Copyright © 2016-present Umbraco
    Generated by DocFX