{"id":18074259,"url":"https://github.com/cijiugechu/vite-plugin-thumbhash","last_synced_at":"2025-07-25T04:38:01.319Z","repository":{"id":151031677,"uuid":"619415712","full_name":"cijiugechu/vite-plugin-thumbhash","owner":"cijiugechu","description":"Bring ThumbHash to your vite project.","archived":false,"fork":false,"pushed_at":"2025-04-05T07:41:22.000Z","size":1161,"stargazers_count":11,"open_issues_count":12,"forks_count":0,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-04-12T05:52:19.189Z","etag":null,"topics":["image","image-processing","napi-rs","thumbhash","thumbnail","vite","vite-plugin"],"latest_commit_sha":null,"homepage":"","language":"TypeScript","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/cijiugechu.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,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2023-03-27T05:12:52.000Z","updated_at":"2025-01-14T19:05:02.000Z","dependencies_parsed_at":"2024-10-31T10:12:08.467Z","dependency_job_id":"32e04851-83ee-49f8-ae32-b9cd07037011","html_url":"https://github.com/cijiugechu/vite-plugin-thumbhash","commit_stats":null,"previous_names":[],"tags_count":6,"template":false,"template_full_name":"jufuku-haijo/ts-lib-starter","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/cijiugechu%2Fvite-plugin-thumbhash","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/cijiugechu%2Fvite-plugin-thumbhash/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/cijiugechu%2Fvite-plugin-thumbhash/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/cijiugechu%2Fvite-plugin-thumbhash/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/cijiugechu","download_url":"https://codeload.github.com/cijiugechu/vite-plugin-thumbhash/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":248525156,"owners_count":21118616,"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":["image","image-processing","napi-rs","thumbhash","thumbnail","vite","vite-plugin"],"created_at":"2024-10-31T10:11:55.405Z","updated_at":"2025-04-12T05:52:27.150Z","avatar_url":"https://github.com/cijiugechu.png","language":"TypeScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# `vite-plugin-thumbhash`\n\nAdd [ThumbHash](https://github.com/evanw/thumbhash) to your vite project.\n\n## Install\n\n```shell\nnpm install vite-plugin-thumbhash --save-dev\n```\n\n```shell\npnpm add vite-plugin-thumbhash -D\n```\n\n## Usage\n\n```ts\nimport { defineConfig } from 'vite'\nimport { thumbHash } from 'vite-plugin-thumbhash'\n\nexport default defineConfig({\n  plugins: [thumbHash()]\n})\n```\n\n```jsx\nimport Image from 'example.jpg?thumb'\n\n//...\n\u003cimg src={Image.thumbSrc}\n     width={Image.thumbWidth}\n     height={Image.thumbHeight}\n/\u003e\n\n\n// If you want to import original image\n\u003cimg src={Image.originalSrc}\n     width={Image.originalWidth}\n     height={Image.originalHeight}\n/\u003e\n```\n\n## TypeScript IntelliSense\n\nAdd the following code to `vite-env.d.ts` :\n```ts\n/// \u003creference types=\"vite-plugin-thumbhash/client\" /\u003e\n```\n\n## Options\n\n```ts\ntype Options =\n    {\n      /**\n       * A picomatch pattern, or array of patterns, \n       * which specifies the files in the build the plugin should operate on. \n       */\n      include?: Array\u003cstring | RegExp\u003e | string | RegExp\n      /**\n       * A picomatch pattern, or array of patterns,\n       * which specifies the files in the build the plugin should ignore.\n       */\n      exclude?: Array\u003cstring | RegExp\u003e | string | RegExp\n      /**\n       * type OutputExtension = 'png' | 'jpg' | 'webp' | 'avif'\n       * @default: 'png'\n       */\n      outputExtension?: OutputExtension\n    }\n```\n\n## Example\n\nsee [playground](/packages/playground/)\n\n## License\n\nMIT \u0026copy; [nemurubaka](https://github.com/cijiugechu)\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fcijiugechu%2Fvite-plugin-thumbhash","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fcijiugechu%2Fvite-plugin-thumbhash","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fcijiugechu%2Fvite-plugin-thumbhash/lists"}