{"id":16773422,"url":"https://github.com/ayusharma/jest-css-module-transformer","last_synced_at":"2025-03-23T15:31:10.926Z","repository":{"id":42854803,"uuid":"260774256","full_name":"ayusharma/jest-css-module-transformer","owner":"ayusharma","description":"A Jest transformer for css and scss files ","archived":false,"fork":false,"pushed_at":"2023-01-06T04:52:06.000Z","size":1097,"stargazers_count":5,"open_issues_count":13,"forks_count":1,"subscribers_count":1,"default_branch":"master","last_synced_at":"2025-03-12T21:18:19.257Z","etag":null,"topics":["css","javascript","jest","postcss","scss","transformer"],"latest_commit_sha":null,"homepage":"","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/ayusharma.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":"2020-05-02T21:01:04.000Z","updated_at":"2023-03-04T05:48:58.000Z","dependencies_parsed_at":"2023-02-05T09:01:36.719Z","dependency_job_id":null,"html_url":"https://github.com/ayusharma/jest-css-module-transformer","commit_stats":null,"previous_names":[],"tags_count":2,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ayusharma%2Fjest-css-module-transformer","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ayusharma%2Fjest-css-module-transformer/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ayusharma%2Fjest-css-module-transformer/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ayusharma%2Fjest-css-module-transformer/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/ayusharma","download_url":"https://codeload.github.com/ayusharma/jest-css-module-transformer/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":245119583,"owners_count":20563763,"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":["css","javascript","jest","postcss","scss","transformer"],"created_at":"2024-10-13T06:45:45.158Z","updated_at":"2025-03-23T15:31:10.588Z","avatar_url":"https://github.com/ayusharma.png","language":"JavaScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"Jest css module transformer\n---\nThis package provides a mock to `*.scss` \u0026 `*.css` files and keeps the class names intact in Jest snapshot\n\n**Original markup**:\n```html\n    \u003cdiv class=`container ${css.marginAuto}`\u003e\n        \u003csection class=`${css.blogSection}`\u003e...\u003c/section\u003e\n    \u003c/div\u003e\n```\n**Snapshot markup without transformation**:\n```html\n    \u003cdiv class=\"container undefined\"\u003e\n        \u003csection class=\"undefined\"\u003e...\u003c/section\u003e\n    \u003c/div\u003e\n```\n**Snapshot markup with transformation**:\n```html\n    \u003cdiv class=\"container marginAuto\"\u003e\n        \u003csection class=\"blogSection\"\u003e...\u003c/section\u003e\n    \u003c/div\u003e\n```\n\n### Installation\n```shell script\n    yarn add --dev @ayusharma/jest-css-module-transformer\n```\n\nOr \n\n```shell script\n    npm install --save-dev @ayusharma/jest-css-module-transformer\n```\n\n### Use\nAdd the following entry in Jest configuration file.\n```javascript\n    transform: {\n        '^.+\\\\.(css|scss)$': '@ayusharma/jest-css-module-transformer'\n    },\n```\n\n\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fayusharma%2Fjest-css-module-transformer","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fayusharma%2Fjest-css-module-transformer","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fayusharma%2Fjest-css-module-transformer/lists"}