Umbraco.Community.SimpleContentApps 0.2.4

There is a newer version of this package available.
See the version list below for details.
dotnet add package Umbraco.Community.SimpleContentApps --version 0.2.4
NuGet\Install-Package Umbraco.Community.SimpleContentApps -Version 0.2.4
This command is intended to be used within the Package Manager Console in Visual Studio, as it uses the NuGet module's version of Install-Package.
<PackageReference Include="Umbraco.Community.SimpleContentApps" Version="0.2.4" />
For projects that support PackageReference, copy this XML node into the project file to reference the package.
paket add Umbraco.Community.SimpleContentApps --version 0.2.4
#r "nuget: Umbraco.Community.SimpleContentApps, 0.2.4"
#r directive can be used in F# Interactive and Polyglot Notebooks. Copy this into the interactive tool or source code of the script to reference the package.
// Install Umbraco.Community.SimpleContentApps as a Cake Addin
#addin nuget:?package=Umbraco.Community.SimpleContentApps&version=0.2.4

// Install Umbraco.Community.SimpleContentApps as a Cake Tool
#tool nuget:?package=Umbraco.Community.SimpleContentApps&version=0.2.4

Umbraco.Community.SimpleContentApps

Umbraco Version NuGet GitHub license Downloads

This packages aims to help developers quickly put together Umbraco ContentApps using C# only.

Basic ContentApp in the Umbraco Office

Features

  • Simplifies C# based ContentApp creation
  • Supports both Views & View Components
  • No package.manifest or lang/lang.xml files required!
  • Variant support (culture specific names)
  • Easy to define Access Rules

Quick Start

Install Package

dotnet add package Umbraco.Community.SimpleContentApps 

Register ContentApp

using Umbraco.Cms.Core.Dashboards;
using Umbraco.Cms.Core.Models.ContentEditing;
using Umbraco.Community.SimpleContentApps.Core;

namespace Umbraco.Community.SimpleContentApps.TestSite;

public class BasicContentApp : ISimpleContentApp
{
    public string Icon => Cms.Core.Constants.Icons.Content;
    public bool ShowInContent => true;
    public bool ShowInContentType => false;
    public bool ShowInMedia => false;
    public bool ShowInMembers => false;
    public IAccessRule[] Rules => new[] { SimpleAccessRule.AllowAdminGroup };
    public int Weight => 0;
    public string Name => "Basic Content App";
    public string? CultureName(string? currentUiCulture) => Name;
    public ContentAppBadge? Badge => ContentAppBadges.None;
}

Create View

  • Your view must go in /Views/ContentApps
  • You view must be the name of your C# class (without ContentApp)
    • For example: BasicContentApp.cs/Views/ContentApps/Basic.cshtml
@using Umbraco.Community.SimpleContentApps.Core.Extensions
@inherits Umbraco.Community.SimpleContentApps.Web.SimpleContentAppViewPage

<h1>Hello Umbraco</h1>
<p>My ContentApp alias is: @Model.ContentApp.Alias()</p>

More Examples

docs/examples.md

Contributing

Contributions to this package are most welcome! Please read the Contributing Guidelines.

Acknowledgments (thanks!)

Product Compatible and additional computed target framework versions.
.NET net6.0 is compatible.  net6.0-android was computed.  net6.0-ios was computed.  net6.0-maccatalyst was computed.  net6.0-macos was computed.  net6.0-tvos was computed.  net6.0-windows was computed.  net7.0 is compatible.  net7.0-android was computed.  net7.0-ios was computed.  net7.0-maccatalyst was computed.  net7.0-macos was computed.  net7.0-tvos was computed.  net7.0-windows was computed.  net8.0 is compatible.  net8.0-android was computed.  net8.0-browser was computed.  net8.0-ios was computed.  net8.0-maccatalyst was computed.  net8.0-macos was computed.  net8.0-tvos was computed.  net8.0-windows was computed. 
Compatible target framework(s)
Included target framework(s) (in package)
Learn more about Target Frameworks and .NET Standard.

NuGet packages

This package is not used by any NuGet packages.

GitHub repositories

This package is not used by any popular GitHub repositories.

Version Downloads Last updated
13.0.0 114 5/25/2024
13.0.0-alpha0001 71 5/25/2024
12.0.0 78 5/25/2024
12.0.0-alpha0001 71 5/25/2024
10.0.0 74 5/25/2024
10.0.0-alpha0001 64 5/25/2024
0.2.6 125 5/11/2024
0.2.5 91 5/6/2024
0.2.4 133 1/4/2024
0.2.3 96 1/4/2024
0.2.2 100 1/4/2024
0.2.1 156 11/10/2023
0.2.0 134 8/25/2023
0.1.0 134 8/24/2023