{"id":15541922,"url":"https://github.com/snewcomer/minify-html-ssr","last_synced_at":"2025-04-23T17:10:26.782Z","repository":{"id":53015004,"uuid":"354710364","full_name":"snewcomer/minify-html-ssr","owner":"snewcomer","description":"For SSR WASM import written in Rust","archived":false,"fork":false,"pushed_at":"2021-04-14T04:05:36.000Z","size":8952,"stargazers_count":4,"open_issues_count":2,"forks_count":2,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-04-19T19:06:36.487Z","etag":null,"topics":["html5","rust-lang"],"latest_commit_sha":null,"homepage":"","language":"Rust","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/snewcomer.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2021-04-05T03:54:35.000Z","updated_at":"2022-06-29T19:58:31.000Z","dependencies_parsed_at":"2022-09-05T02:50:38.978Z","dependency_job_id":null,"html_url":"https://github.com/snewcomer/minify-html-ssr","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/snewcomer%2Fminify-html-ssr","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/snewcomer%2Fminify-html-ssr/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/snewcomer%2Fminify-html-ssr/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/snewcomer%2Fminify-html-ssr/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/snewcomer","download_url":"https://codeload.github.com/snewcomer/minify-html-ssr/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":250477812,"owners_count":21437049,"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":["html5","rust-lang"],"created_at":"2024-10-02T12:20:02.637Z","updated_at":"2025-04-23T17:10:26.748Z","avatar_url":"https://github.com/snewcomer.png","language":"Rust","funding_links":[],"categories":[],"sub_categories":[],"readme":"# minify-html-ssr\nFor SSR WASM import.\n\n## What it does\n\nThis library removes extraneous whitespaces between HTML tags. Single spaces are preserved where necessary.\n\n## Directions\n\n### Local\n1. wasm-pack build --target=nodejs --out-dir path-to-node-project\n2. import and add `const { minify_html } = require('../utils/minify-html/html_whitespace');` to your render pipeline.\n\n```\nres.send(minify_html(body));\n```\n### npm package\n1. `npm install minify-html-ssr`\n2. Minify the html body before sent down.\n\n## Downsides\n- This is a runtime library. It is meant to work fast for you.  However, a build time solution that collapses whitespace might be better for your app.\n\n- Do you brotli compress your HTML?  If not, you might be able to drop ~30% of your characters versus gzip.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fsnewcomer%2Fminify-html-ssr","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fsnewcomer%2Fminify-html-ssr","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fsnewcomer%2Fminify-html-ssr/lists"}