{"_id":"@dubortoto/craco-sass-resources-loader","name":"@dubortoto/craco-sass-resources-loader","dist-tags":{"latest":"1.0.0"},"versions":{"1.0.0":{"name":"@dubortoto/craco-sass-resources-loader","version":"1.0.0","description":"A craco plugin to use sass-resources-loader with create-react-app","repository":{"type":"git","url":"git+https://github.com/Jonny-china/craco-sass-resources-loader.git"},"main":"index.js","author":{"name":"Jonny Chen"},"license":"MIT","keywords":["craco","create-react-app","react","webpack","sass","sass-resources-loader"],"devDependencies":{"@craco/craco":"^7.1.0","commitlint":"^12.1.4","eslint":"7.27.0","eslint-config-prettier":"^8.3.0","eslint-plugin-prettier":"^3.0.1","husky":"^1.1.3","jest":"^27.0.1","lint-staged":"^11.0.0","prettier":"^2.3.0","react-scripts":"^5.0.1"},"peerDependencies":{"@craco/craco":"^7.1.0","react-scripts":"^5.0.1"},"dependencies":{"sass-resources-loader":"^2.2.1"},"husky":{"hooks":{"commit-msg":"commitlint -E HUSKY_GIT_PARAMS","pre-commit":"lint-staged"}},"lint-staged":{"index.js":["eslint --quiet --fix","git add"]},"gitHead":"c4775e3a61b76dcff3c9d1ddaa2d3803dea96070","bugs":{"url":"https://github.com/Jonny-china/craco-sass-resources-loader/issues"},"homepage":"https://github.com/Jonny-china/craco-sass-resources-loader#readme","_id":"@dubortoto/craco-sass-resources-loader@1.0.0","_nodeVersion":"16.20.1","_npmVersion":"8.19.4","dist":{"integrity":"sha512-AGsT28ojcpmg8EXTJm9CJgLkRWHRawvgPy7cuaXnn5OAaglWGR1k5TTuTIJvRajtFZYqYIfylsktVa0FNpM6SA==","shasum":"5beba718fb0a8c1fe463a5dff439e46df9b57668","tarball":"https://registry.npmjs.org/@dubortoto/craco-sass-resources-loader/-/craco-sass-resources-loader-1.0.0.tgz","fileCount":4,"unpackedSize":5164,"signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIQD+AX1Wv8tHqvPHfLWzhYf/noMhNKvuGySAwi8Z+qMhVgIgIVPFhncFoOFLNEq3DeYksIQMjwMcxhPCPwaky3xTPWA="}]},"_npmUser":{"name":"dubortoto","email":"edu-bortoto@hotmail.com"},"directories":{},"maintainers":[{"name":"dubortoto","email":"edu-bortoto@hotmail.com"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/craco-sass-resources-loader_1.0.0_1715888526422_0.8109608501706642"},"_hasShrinkwrap":false}},"time":{"created":"2024-05-16T19:42:06.293Z","1.0.0":"2024-05-16T19:42:06.547Z","modified":"2024-05-16T19:42:06.831Z"},"maintainers":[{"name":"dubortoto","email":"edu-bortoto@hotmail.com"}],"description":"A craco plugin to use sass-resources-loader with create-react-app","homepage":"https://github.com/Jonny-china/craco-sass-resources-loader#readme","keywords":["craco","create-react-app","react","webpack","sass","sass-resources-loader"],"repository":{"type":"git","url":"git+https://github.com/Jonny-china/craco-sass-resources-loader.git"},"author":{"name":"Jonny Chen"},"bugs":{"url":"https://github.com/Jonny-china/craco-sass-resources-loader/issues"},"license":"MIT","readme":"# Craco sass-resources-loader\r\n\r\n> Modify with [tilap/craco-sass-resources-loader](https://github.com/tilap/craco-sass-resources-loader)\r\n\r\n[![MIT License](https://img.shields.io/badge/license-MIT-blue.svg)](LICENSE)\r\n\r\nThis is a [craco](https://github.com/sharegate/craco) plugin to add [sass-resources-loader](https://www.npmjs.com/package/sass-resources-loader) with [create-react-app](https://facebook.github.io/create-react-app/) version >= 2.\r\n\r\n## Installation\r\n\r\n```bash\r\n$ yarn add -D @jonny1994/craco-sass-resources-loader\r\n\r\n# OR\r\n\r\n$ npm install @jonny1994/craco-sass-resources-loader --save-dev\r\n```\r\n\r\n## Usage\r\n\r\n`craco-sass-resources-loader` expect a `resources` option containing a string or an array of\r\nstring pointing the scss files your want to load before any scss/sass file.\r\n\r\n```js\r\nconst sassResourcesLoader = require('@jonny1994/craco-sass-resources-loader');\r\n\r\nmodule.exports = {\r\n  plugins: [\r\n    {\r\n      plugin: sassResourcesLoader,\r\n      options: {\r\n        hoistUseStatements: false,\r\n        resources: './src/my-config-theme.scss',\r\n      },\r\n    },\r\n  ],\r\n}\r\n```\r\n\r\nYou can load multiple scss resources files too:\r\n\r\n```js\r\nconst sassResourcesLoader = require('craco-sass-resources-loader');\r\n\r\nmodule.exports = {\r\n  plugins: [\r\n    {\r\n      plugin: sassResourcesLoader,\r\n      options: {\r\n        resources: [\r\n          './src/my-config-theme.scss',\r\n          './src/my-other-config-theme.scss'\r\n        ],\r\n      },\r\n    },\r\n  ],\r\n}\r\n```\r\n","readmeFilename":"README.md"}