A lightweight, modular C# to HTML converter library which takes raw C# and converts it to well-structured HTML.
- .NET 6.0 or later
- Clone the repository:
git clone https://github.com/atskas/HyperSharp
cd HyperSharp- Build the library:
dotnet build HyperSharp.Library/HyperSharp.Library.csprojThis produces HyperSharp.Library.dll in the bin folder.
- Reference the library in your project:
dotnet add path/to/Project.csproj reference HyperSharp.Library/HyperSharp.Library.csprojStart working with HyperSharp by creating a new HtmlDocument:
private static HtmlDocument Document = new();Use its methods to define HTML structure and elements programmatically.
You can customize the output by setting the following properties:
OutputFileName- Name of the generated HTML file (default:output.html)OutputPath- Directory where the output file is saved (default:Documents/HyperSharp_Output)UserCssPath- Optional path to a custom CSS file or directory for styling the generated HTML
You can run the demo project to check out HyperSharp's possibilities.
dotnet run --project HyperSharp.Testing/HyperSharp.Testing.csprojSee GitHub's contribution guide if you’d like to help out!
