AspNetCore.SwaggerUI.Themes
0.5.0
See the version list below for details.
dotnet add package AspNetCore.SwaggerUI.Themes --version 0.5.0
NuGet\Install-Package AspNetCore.SwaggerUI.Themes -Version 0.5.0
<PackageReference Include="AspNetCore.SwaggerUI.Themes" Version="0.5.0" />
paket add AspNetCore.SwaggerUI.Themes --version 0.5.0
#r "nuget: AspNetCore.SwaggerUI.Themes, 0.5.0"
// Install AspNetCore.SwaggerUI.Themes as a Cake Addin #addin nuget:?package=AspNetCore.SwaggerUI.Themes&version=0.5.0 // Install AspNetCore.SwaggerUI.Themes as a Cake Tool #tool nuget:?package=AspNetCore.SwaggerUI.Themes&version=0.5.0
AspNetCore.SwaggerUI.Themes
Introduction
Swashbuckle.AspNetCore is a popular library for adding Swagger support to ASP.NET Core projects, making it easier to document and interact with your APIs.
AspNetCore.SwaggerUI.Themes builds upon Swashbuckle.AspNetCore.SwaggerUI, enhancing the Swagger UI with modern and visually appealing themes.
Features
- New Themes: enhances the Swagger documentation interface with various themes, including a default style that preserves the classic Swagger UI appearance and introduces new modern styles.
- Seamless Integration: simply install the package and add the style parameter to the existing method used for SwaggerUI.
Modern styles come with additional functionalities, including pinned topbar and back-to-top button.
Getting Started
To use AspNetCore.SwaggerUI.Themes in your ASP.NET Core project, follow these steps:
Install the package using .NET CLI or NuGet Package Manager:
dotnet add package AspNetCore.SwaggerUI.Themes
or
Install-Package AspNetCore.SwaggerUI.Themes
In your
Program.cs
file, add the style through theStyle
orModernStyle
class as new parameter ofapp.UseSwaggerUI()
method:using AspNetCore.SwaggerUI.Themes; ... app.UseSwaggerUI(Style.Dark);
This code enables the chosen theme for Swagger UI in your application.
Please be aware that for projects utilizing the older style template with separate
Startup.cs
andProgram.cs
files, the previously code should be configured within theConfigure
method of theStartup
class.
Available Themes
There are a few styles available for your Swagger UI.
Defaults:
• Dark
Offers a simple dark-themed interface, maintaining the classic Swagger UI layout.
Style.Dark
• Forest
Inspired by the colors of a forest, this theme brings a natural and vibrant feel to your documentation.
Style.Forest
• DeepSea
Inspired by the depths of the sea, this theme features cool blues and deep greens for a tranquil and immersive experience.
Style.DeepSea
• Desert
Inspired by the essence of the desert, this theme evokes warm tones and sandy hues for an immersive experience.
Style.Desert
The light style is not in this list because it's just the default one used by Swagger UI; to use that you don't need this library.
Moderns:
• Light
Offers a modern, light-themed interface that overrides some aspects of the default Swagger UI.
ModernStyle.Light
• Dark
Provides a sleek, dark-themed interface for a more modern look and feel.
ModernStyle.Dark
• Forest
Brings a natural feel to your documentation with colors inspired by the serene ambiance of a forest.
ModernStyle.Forest
• DeepSea
Dive into a tranquil interface with cool blues and deep greens, inspired by the depths of the sea.
ModernStyle.DeepSea
• Desert
Immerse yourself in a desert-inspired theme, characterized by warm tones and sandy hues.
ModernStyle.Desert
• Futuristic
Experience a futuristic neon-inspired interface for a modern browsing experience.
ModernStyle.Futuristic
Product | Versions 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. |
-
net6.0
- Swashbuckle.AspNetCore.SwaggerUI (>= 6.5.0)
-
net7.0
- Swashbuckle.AspNetCore.SwaggerUI (>= 6.5.0)
-
net8.0
- Swashbuckle.AspNetCore.SwaggerUI (>= 6.5.0)
NuGet packages
This package is not used by any NuGet packages.
GitHub repositories
This package is not used by any popular GitHub repositories.