{"id":18962251,"url":"https://github.com/lipp/fit-text","last_synced_at":"2025-04-19T11:52:51.848Z","repository":{"id":57237531,"uuid":"151719540","full_name":"lipp/fit-text","owner":"lipp","description":"A fit text to width responsive web component","archived":false,"fork":false,"pushed_at":"2018-10-24T07:26:45.000Z","size":969,"stargazers_count":8,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"master","last_synced_at":"2025-04-15T20:47:23.819Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":"https://fit-text.now.sh/examples/","language":"JavaScript","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/lipp.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-10-05T12:46:34.000Z","updated_at":"2024-06-05T09:47:31.000Z","dependencies_parsed_at":"2022-08-26T15:10:17.245Z","dependency_job_id":null,"html_url":"https://github.com/lipp/fit-text","commit_stats":null,"previous_names":[],"tags_count":3,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/lipp%2Ffit-text","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/lipp%2Ffit-text/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/lipp%2Ffit-text/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/lipp%2Ffit-text/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/lipp","download_url":"https://codeload.github.com/lipp/fit-text/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":249688629,"owners_count":21311257,"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":[],"created_at":"2024-11-08T14:15:45.589Z","updated_at":"2025-04-19T11:52:51.826Z","avatar_url":"https://github.com/lipp.png","language":"JavaScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# fit-text\n\nA very basic and lightweight vanilla fit-text web component, which adjusts the font-size to fit the parent container width.\n\n[![Demo](./demo.gif)](https://fit-text.now.sh/examples/tiles.html)\n\n.\n\n## Highlights\n\n - vanilla web component / custom element\n - less than 600 byte (minified + gzip)\n - no dependencies\n - no additional css / js required\n - supports custom fonts\n\nThe implementation relies on custom elements and shadow dom parts of the web component specs\n([check support](https://developer.mozilla.org/en-US/docs/Web/Web_Components#Browser_support)).\nFor using custom fonts, the browser must support the `FontFaceSet` API (`onloadingdone` event,\n[check support](https://developer.mozilla.org/kab/docs/Web/API/FontFaceSet#Browser_compatibility))\n\nThus, not every major Browser is supported yet.\n\n# Demo\n\nPlay with this demo on [codepen.io](https://codepen.io/lipp/pen/YJGvEe?editors=1100#0).\n\n# Usage\n\n```html\n\u003cscript src=\"https://unpkg.com/fit-text-webcomponent\"\u003e\u003c/script\u003e\n\n\u003cdiv style=\"width: 50vw;\"\u003e\n  \u003cfix-text\u003eThis fits to 50vw\u003c/fit-text\u003e\n\u003c/div\u003e\n```\n\nAlso checkout the [examples directory](./examples). They are deployed [here](https://fit-text.now.sh/examples/)\n\n\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Flipp%2Ffit-text","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Flipp%2Ffit-text","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Flipp%2Ffit-text/lists"}