{"id":33933973,"url":"https://github.com/8176135/inline-assets-rs","last_synced_at":"2026-03-27T04:05:48.945Z","repository":{"id":32674372,"uuid":"139383452","full_name":"8176135/inline-assets-rs","owner":"8176135","description":"A Rust library for inlining Javascript, CSS, and font files into your html files for easy distribution.","archived":false,"fork":false,"pushed_at":"2022-02-19T04:49:59.000Z","size":442,"stargazers_count":8,"open_issues_count":6,"forks_count":2,"subscribers_count":1,"default_branch":"master","last_synced_at":"2025-08-15T01:44:06.628Z","etag":null,"topics":["inline-assets","inline-css","inline-javascript","library","rust"],"latest_commit_sha":null,"homepage":null,"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/8176135.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":"2018-07-02T02:54:34.000Z","updated_at":"2023-12-13T13:09:46.000Z","dependencies_parsed_at":"2022-08-07T18:00:32.457Z","dependency_job_id":null,"html_url":"https://github.com/8176135/inline-assets-rs","commit_stats":null,"previous_names":["hand-of-cthulhu/inline-assets-rs"],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/8176135/inline-assets-rs","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/8176135%2Finline-assets-rs","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/8176135%2Finline-assets-rs/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/8176135%2Finline-assets-rs/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/8176135%2Finline-assets-rs/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/8176135","download_url":"https://codeload.github.com/8176135/inline-assets-rs/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/8176135%2Finline-assets-rs/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":31018546,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-03-27T03:51:26.850Z","status":"ssl_error","status_checked_at":"2026-03-27T03:51:09.693Z","response_time":164,"last_error":"SSL_read: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"can_crawl_api":true,"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":["inline-assets","inline-css","inline-javascript","library","rust"],"created_at":"2025-12-12T13:20:55.652Z","updated_at":"2026-03-27T04:05:48.931Z","avatar_url":"https://github.com/8176135.png","language":"Rust","funding_links":[],"categories":[],"sub_categories":[],"readme":"inline-assets-rs\n=====\n[![Build Status](https://travis-ci.org/Hand-of-Cthulhu/inline-assets-rs.svg?branch=master)](https://travis-ci.org/Hand-of-Cthulhu/inline-assets-rs)\n[![Crates.io](https://meritbadge.herokuapp.com/inline-assets)](https://crates.io/crates/inline-assets)\n[![Docs.rs](https://docs.rs/inline_assets/badge.svg)](https://docs.rs/inline_assets/)\n[![MIT licensed](https://img.shields.io/badge/license-MIT-blue.svg)](https://raw.githubusercontent.com/Hand-of-Cthulhu/inline-assets-rs/master/LICENSE)\n\nA Rust library for inlining Javascript, CSS, and font files into your html files for easy distribution.\nThis also changes `url(local_path)` in the css to be relative to the html file.\n\nOriginally intended to be used in build scripts of [web_view](https://github.com/Boscop/web-view \"Rust bindings to zserge/webview\") projects.\nThe output can also be able to be piped into [minifier-rs](https://github.com/GuillaumeGomez/minifier-rs) to save space.\n\n### Usage:\nUsage is really simple, just call `inline_assets::inline_html_string(file_path, inline_assets::Config::default())`, with the html file path. \n\nThe config currently provides 2 options (with the default being both enabled):\n* `inline_fonts`: Whether or not to inline fonts in the css as base64.\n* `remove_new_lines`:  Replace `\\r` and `\\r\\n` with a space character. Useful to keep line numbers the same in the output to help with debugging.\n\nLook in the example folder for a CLI binary example.\n\nAll font files should work if font format is set correctly. i.e.`src: url(font-file) format(font-format)`\n\nTo import CSS recursively, use `@import url(path_to_another_css_file);` in your css files. Multiple imports of the same CSS file will only be imported once.\n\n### TODO:\n* Support inlining images","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2F8176135%2Finline-assets-rs","html_url":"https://awesome.ecosyste.ms/projects/github.com%2F8176135%2Finline-assets-rs","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2F8176135%2Finline-assets-rs/lists"}