{"id":19258948,"url":"https://github.com/lassehaslev/fit-text","last_synced_at":"2026-06-29T22:30:22.855Z","repository":{"id":89976091,"uuid":"79607644","full_name":"LasseHaslev/fit-text","owner":"LasseHaslev","description":"Resizes text to fit width of parent","archived":false,"fork":false,"pushed_at":"2017-06-15T12:34:27.000Z","size":11,"stargazers_count":1,"open_issues_count":0,"forks_count":0,"subscribers_count":2,"default_branch":"master","last_synced_at":"2025-01-05T09:29:20.633Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"JavaScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/LasseHaslev.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"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":"2017-01-20T22:54:40.000Z","updated_at":"2023-03-05T01:46:03.000Z","dependencies_parsed_at":"2023-05-30T18:00:21.394Z","dependency_job_id":null,"html_url":"https://github.com/LasseHaslev/fit-text","commit_stats":null,"previous_names":[],"tags_count":4,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/LasseHaslev%2Ffit-text","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/LasseHaslev%2Ffit-text/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/LasseHaslev%2Ffit-text/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/LasseHaslev%2Ffit-text/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/LasseHaslev","download_url":"https://codeload.github.com/LasseHaslev/fit-text/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":240356192,"owners_count":19788513,"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-09T19:14:51.619Z","updated_at":"2026-06-29T22:30:22.784Z","avatar_url":"https://github.com/LasseHaslev.png","language":"JavaScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# @lassehaslev/fit-text\n\n\u003e Resizes text to fit width of parent\n\n## Install\n\nRun ```npm install @lassehaslev/fit-text --save``` in your project folder.\n\n## Usage\n\n```js\nimport FitText from '@lassehaslev/fit-text';\nvar element = document.querySelector( '.fittext-multiline' );\n\n// Use default options\nnew FitText( element );\n\n// Overwrite defaults\nnew FitText( element, {\n    compressor: .1,\n    minFontSize: Number.NEGATIVE_INFINITY,\n    maxFontSize: Number.POSITIVE_INFINITY,\n    multiline: false,\n    watch: true,\n    widthMargin: 0,\n    unit: 'em',\n    debugColor: null, // Only for debuging\n} );\n```\n\n\n## Build Setup\n\n``` bash\n# install dependencies\nnpm install\n\n# serve with hot reload\nnpm run dev\n```\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Flassehaslev%2Ffit-text","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Flassehaslev%2Ffit-text","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Flassehaslev%2Ffit-text/lists"}