{"id":14986228,"url":"https://github.com/xuanchenlin/nanui","last_synced_at":"2025-05-16T01:00:32.469Z","repository":{"id":37236813,"uuid":"60672374","full_name":"XuanchenLin/NanUI","owner":"XuanchenLin","description":"NanUI is an open source .NET project for developers who want to create Windows desktop applications with HTML, CSS and JavaScript.","archived":false,"fork":false,"pushed_at":"2025-03-19T04:53:10.000Z","size":83305,"stargazers_count":3763,"open_issues_count":1,"forks_count":663,"subscribers_count":157,"default_branch":"master","last_synced_at":"2025-05-09T00:54:57.208Z","etag":null,"topics":["cef","cefglue","chromium","desktop","dotnet","dotnet-core","formium","html-window","nanui","winforms"],"latest_commit_sha":null,"homepage":"https://github.com/Xuanchenlin/NanUI","language":"C#","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/XuanchenLin.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":".github/FUNDING.yml","license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null},"funding":{"open_collective":"nanui","custom":["https://www.paypal.com/paypalme/mrjson","https://raw.githubusercontent.com/NetDimension/NanUI/master/docs/images/qrcode.png"]}},"created_at":"2016-06-08T05:57:40.000Z","updated_at":"2025-04-29T11:16:18.000Z","dependencies_parsed_at":"2024-11-06T12:40:09.853Z","dependency_job_id":"91d12556-d2cd-4ee2-905c-7f88c8aa61cf","html_url":"https://github.com/XuanchenLin/NanUI","commit_stats":{"total_commits":451,"total_committers":9,"mean_commits":"50.111111111111114","dds":"0.21286031042128606","last_synced_commit":"5758ae48716d7fa1f5fe44c83c68a7ffa4b7b776"},"previous_names":[],"tags_count":2,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/XuanchenLin%2FNanUI","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/XuanchenLin%2FNanUI/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/XuanchenLin%2FNanUI/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/XuanchenLin%2FNanUI/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/XuanchenLin","download_url":"https://codeload.github.com/XuanchenLin/NanUI/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":254448578,"owners_count":22072764,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["cef","cefglue","chromium","desktop","dotnet","dotnet-core","formium","html-window","nanui","winforms"],"created_at":"2024-09-24T14:12:33.746Z","updated_at":"2025-05-16T01:00:27.416Z","avatar_url":"https://github.com/XuanchenLin.png","language":"C#","funding_links":["https://opencollective.com/nanui","https://www.paypal.com/paypalme/mrjson","https://raw.githubusercontent.com/NetDimension/NanUI/master/docs/images/qrcode.png","https://paypal.me/mrjson?country.x=C2\u0026locale.x=zh_XC"],"categories":[],"sub_categories":[],"readme":"﻿\u003cp align=\"center\"\u003e\n    \u003cimg src=\"./artworks/WinFormiumLogo.png\" width=\"144\" /\u003e\n\u003c/p\u003e\n\u003ch1 align=\"center\"\u003eThe NanUI Project\u003c/h1\u003e\n\u003cp align=\"center\"\u003e\u003cstrong\u003eEasily build powerful WinForm applications with HTML, CSS and JavaScript.\u003c/strong\u003e\u003c/p\u003e\n\n# NanUI\n\n点击[[此处]](https://gitee.com/dotNetChina/NanUI/)切换到**简体中文**仓库首页。\n\n![GitHub](https://img.shields.io/github/license/XuanchenLin/NanUI)\n![Nuget](https://img.shields.io/nuget/v/NetDimension.NanUI)\n![Nuget](https://img.shields.io/nuget/dt/NetDimension.NanUI)\n\n## ⭐ About\n\nNanUI is an open source framework on .NET platform for creating user interface for WinForm Applications using HTML5, CSS3, and JavaScript. It is based on the [Xilium.CefGlue](https://bitbucket.org/xilium/xilium.cefglue/wiki/Home) project, which is a .NET wrapper around the [Chromium Embedded Framework](https://bitbucket.org/chromiumembedded/cef).\n\nIf you are looking for a framework for creating a WinForm application with a modern user interface, NanUI is a good choice. you can use HTML, CSS, and JavaScript to create a user interface, and use C# to write the business logic of the application.\n\n**Please give NanUI project a star⭐ if you like it.**\n\nIf this project helps, please consider funding it.\n\n[![Donate](https://img.shields.io/badge/Donate-PayPal-green.svg)](https://paypal.me/mrjson?country.x=C2\u0026locale.x=zh_XC)\n\n## 🖥️ Requirements\n\n**For Development**\n\n- .NET Framework 4.6.2 or higher / .NET 6.0 or higher\n- Visual Studio 2019 or higher (VS2022 is recommended)\n\n**For Deployment**\n\n- Microsoft Windows 7 Service Pack 1 or higher\n- .Net Framework 4.6.2 or higher\n- .NET 6.0 for Windows 7 and higher.\n- .NET 7.0/8.0 for Windows 10 and higher.\n\nThis is a **Windows Only** framework, it can not run on Linux or Mac OS.\n\nThe minimum supported Windows is Windows 7 Service Pack 1, and some features (such as DirectComposition Offscreen Rendering) are not supported on Windows 7.\n\n## 🧰 Getting Started\n\nCreate a simple NanUI Application by following the steps below:\n\n**1. Create a WinForm Application by default template.**\n\n**2. Install NanUI NuGet Package**\n\nOpen the NuGet Package Manager to install or use NuGet Package Manager Console, and run the following command to install NanUI nuget package:\n\n```powershell\nPM\u003e Install-Package NetDimension.NanUI\n```\n\nInstall the dependencies of Chromium Embedded Framework that NanUI depends on:\n\n```powershell\nPM\u003e Install-Package NetDimension.NanUI.Runtime\n```\n\n**3. A basic NanUI application requires the following code:**\n\nModify the code in the **Program.cs** file as follows:\n\n```csharp\nusing WinFormium;\n\nclass Program\n{\n    [STAThread]\n    static void Main(string[] args)\n    {\n        var builder = NanUIApp.CreateBuilder();\n\n        builder.UseNanUIApp\u003cMyApp\u003e();\n\n        var app = builder.Build();\n\n        app.Run();\n    }\n}\n```\n\nCreate a class implements **NanUIAppStartup** for configuring the application:\n\n```csharp\nusing NetDimension.NanUI;\n\nclass MyAPP : NanUIAppStartup\n{\n    protected override MainWindowCreationAction? UseMainWindow(MainWindowOptions opts)\n    {\n        // Configure the main window of this application\n        return opts.UseMainFormium\u003cMyWindow\u003e();\n    }\n\n    protected override void ProgramMain(string[] args)\n    {\n        // The codes in Main function should be here, this function only runs in Main process. So it can prevent the codes in Main process running in sub-processes.\n        ApplicationConfiguration.Initialize();\n    }\n\n    protected override void ConfigurationChromiumEmbedded(ChromiumEnvironmentBuiler cef)\n    {\n        // Configure the Chromium Embedded Framework here\n    }\n\n    protected override void ConfigureServices(IServiceCollection services)\n    {\n        // Configure the services of this application here\n    }\n}\n```\n\nCreate a class implements **Formium** for configuring the main window of the application:\n\n```csharp\nusing NetDimension.NanUI;\nusing NetDimension.NanUI.Forms;\n\nclass MyWindow : Formium\n{\n    public MyWindow()\n    {\n        Url = \"https://www.google.com\";\n    }\n\n    protected override FormStyle ConfigureWindowStyle(WindowStyleBuilder builder)\n    {\n        // Configure the style of the window here or leave it blank to use the default style\n\n        var style = builder.UseSystemForm();\n\n        style.TitleBar = false;\n\n        style.DefaultAppTitle = \"My first WinFomrim app\";\n\n        return style;\n    }\n}\n```\n\n**4. Build and run your NanUI application**\n\n## 📖 Documentation\n\nFor more info please see - [Documentation](docs/README.md)\n\n## 🤖 Demos\n\n- [Minimal WinFormium App](./examples/MinimalWinFormiumApp) - Introduction to the basic usage of WinFormium.\n\n## 🔗 Third-Party References \u0026 Tools\n\n- CEF - [https://bitbucket.org/chromiumembedded/cef](https://bitbucket.org/chromiumembedded/cef)\n- Xilium.CefGlue - [https://gitlab.com/xiliumhq/chromiumembedded/cefglue/](https://gitlab.com/xiliumhq/chromiumembedded/cefglue)\n- Vanara.Library - [https://github.com/dahall/Vanara](https://github.com/dahall/Vanara)\n- Vortice.Windows - [https://github.com/amerkoleci/Vortice.Windows](https://github.com/amerkoleci/Vortice.Windows)\n- SkiaSharp - [https://github.com/mono/SkiaSharp](https://github.com/mono/SkiaSharp)\n- React - [https://github.com/facebook/react](https://github.com/facebook/react)\n- React-Router - [https://github.com/remix-run/react-router](https://github.com/remix-run/react-router)\n- Vite - [https://github.com/vitejs/vite](https://github.com/vitejs/vite)\n\n## 🏆 Inspirations\n\nI was inspired by the following songs and albums when creating this version of WinFormium.\n\n- **Strandels** - Chance Of Rain\n- **One Direction** - What a Feeling (Made In The A.M.)\n- **Thomas Rhett** - VHS (Center Point Road)\n- **Sammy Kershaw** - She Don't Know She's Beautiful (Haunted Heart)\n- **Chrissy Steele** - Two Bodies (Magnet To Steele)\n- **Halestorm** - I Like It Heavy (Into the Wild Life)\n- **Joan Jett \u0026 The Blackhearts** - I Hate Myself for Loving You (Up Your Alley)\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fxuanchenlin%2Fnanui","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fxuanchenlin%2Fnanui","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fxuanchenlin%2Fnanui/lists"}