{"id":20945570,"url":"https://github.com/jkamsker/nminify","last_synced_at":"2025-04-11T16:24:24.528Z","repository":{"id":65338334,"uuid":"589770410","full_name":"JKamsker/NMinify","owner":"JKamsker","description":"Wrapper for minify, which minifies web formats","archived":false,"fork":false,"pushed_at":"2024-05-03T17:13:09.000Z","size":35,"stargazers_count":2,"open_issues_count":0,"forks_count":0,"subscribers_count":2,"default_branch":"master","last_synced_at":"2025-04-11T16:24:20.104Z","etag":null,"topics":["csharp","css","dotnet","go","golang","html","javascript","js","json","minifier","minify","net-7","nminify","svg","xml"],"latest_commit_sha":null,"homepage":"","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/JKamsker.png","metadata":{"files":{"readme":"Readme.md","changelog":null,"contributing":null,"funding":null,"license":"License.md","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}},"created_at":"2023-01-16T22:27:05.000Z","updated_at":"2024-10-31T07:45:10.000Z","dependencies_parsed_at":"2024-11-18T23:50:38.721Z","dependency_job_id":"bfba42d4-ab23-44f9-9fff-65668a2ababf","html_url":"https://github.com/JKamsker/NMinify","commit_stats":{"total_commits":14,"total_committers":1,"mean_commits":14.0,"dds":0.0,"last_synced_commit":"9dc573454959d9d827ae499c1d25dc16ce1562a7"},"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/JKamsker%2FNMinify","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/JKamsker%2FNMinify/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/JKamsker%2FNMinify/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/JKamsker%2FNMinify/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/JKamsker","download_url":"https://codeload.github.com/JKamsker/NMinify/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":248438922,"owners_count":21103502,"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":["csharp","css","dotnet","go","golang","html","javascript","js","json","minifier","minify","net-7","nminify","svg","xml"],"created_at":"2024-11-18T23:48:53.516Z","updated_at":"2025-04-11T16:24:24.493Z","avatar_url":"https://github.com/JKamsker.png","language":"C#","funding_links":[],"categories":[],"sub_categories":[],"readme":"\u003cp align=\"center\"\u003e\n  \u003ca href=\"https://github.com/JKamsker/NMinify\"\u003e\n    \u003cpicture\u003e\n      \u003csource media=\"(prefers-color-scheme: dark)\" srcset=\"https://user-images.githubusercontent.com/11245306/213277904-0129ae88-f655-4e03-a723-e5bac4b864e1.png\"\u003e\n      \u003cimg src=\"https://user-images.githubusercontent.com/11245306/213277904-0129ae88-f655-4e03-a723-e5bac4b864e1.png\" height=\"128\" alt=\"NMinify logo\"\u003e\n    \u003c/picture\u003e\n    \u003cp align=\"center\"\u003eMinify HTML, CSS, JS and more\u003c/p\u003e\n  \u003c/a\u003e\n\u003c/p\u003e\n\n[![NuGet version (NMinify)](https://img.shields.io/nuget/v/NMinify.svg?style=flat-square)](https://www.nuget.org/packages/NMinify)\n[![Nuget](https://img.shields.io/nuget/dt/NMinify)](https://www.nuget.org/packages/NMinify)\n[![GitHub Workflow Status](https://img.shields.io/github/actions/workflow/status/JKamsker/NMinify/build-dependency.yaml?branch=master)](https://github.com/JKamsker/NMinify/actions)\n[![GitHub license](https://img.shields.io/github/license/JKamsker/NMinify)](https://github.com/JKamsker/NMinify/blob/master/LICENSE.txt)\n[![PR](https://img.shields.io/badge/PR-Welcome-blue)](https://github.com/JKamsker/NMinify/pulls)\n\n## Introduction\nNMinify is a Wrapper for the [golang library minify](https://github.com/tdewolff/minify). \u003cbr/\u003e\nMinification is the process of removing bytes from a file (such as whitespace) without changing its output and therefore shrinking its size and speeding up transmission over the internet and possibly parsing. The implemented minifiers are designed for high performance.\n\n## Installation\n\nTo install NMinify, run the following command in the Package Manager Console:\n\n```\nInstall-Package NMinify\n```\n\nYou can also install NMinify via the .NET CLI by running:\n```\ndotnet add package NMinify\n```\n\nAlternatively, you can add NMinify as a dependency in your project's `.csproj` file:\n\n```xaml\n\u003cItemGroup\u003e\n  \u003cPackageReference Include=\"NMinify\" Version=\"x.x.x\" /\u003e\n\u003c/ItemGroup\u003e\n``` \n\nMake sure to replace `x.x.x` with the latest version available on [NuGet](https://www.nuget.org/packages/NMinify/).\n\nOnce NMinify is installed, you can start using it in your project by adding `using NMinify;` to the top of your file.\n\n## Basic Usage\n\n```csharp\nvar text = \"\u003cspan style=\\\"color:#ff0000;\\\" class=\\\"text\\\"\u003eSome  text\u003c/span\u003e\";\nvar minifier = new Minifier();\nvar minified = minifier.MinifyString(MinifierMediaType.Html, text);\n\n\nConsole.WriteLine(text); // Output: \u003cspan style=\"color:#ff0000;\" class=\"text\"\u003eSome  text\u003c/span\u003e\nConsole.WriteLine(minified); // Output: \u003cspan style=color:red class=text\u003eSome text\u003c/span\u003e\n```\n\n## Available Methods\n```csharp\nSpan\u003cbyte\u003e MinifyBytes(MinifierMediaType mediaType, ReadOnlySpan\u003cbyte\u003e input, Span\u003cbyte\u003e output);\nstring MinifyFile(string mediatype, string input);\nstring MinifyString(MinifierMediaType mediaType, string input);\n```\n\n# License\n\nNMinify is released under the [MIT License](https://opensource.org/licenses/MIT). This means that you are free to use, modify, and distribute this software as long as you include the original copyright and license notice in your distribution.\n\nPlease note that the underlying minify library by tdewolff is also released under the MIT License, and its copyright and license must also be included in any distribution of NMinify.\n\nBy using NMinify, you are agreeing to the terms of the MIT License. If you do not agree to these terms, you should not use this software.\n\n----------\n\n\u003cp align=\"center\"\u003eMade with \u003ca href=\"https://stackedit.io/\"\u003estackedit.io\u003c/a\u003e, \u003ca href=\"https://github.com/tdewolff/minify\"\u003eminify\u003c/a\u003e and lots of ❤️ in Austria\u003c/p\u003e\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fjkamsker%2Fnminify","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fjkamsker%2Fnminify","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fjkamsker%2Fnminify/lists"}