Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/cjsheets/gatsby-plugin-typescript-scss-modules
https://github.com/cjsheets/gatsby-plugin-typescript-scss-modules
Last synced: 13 days ago
JSON representation
- Host: GitHub
- URL: https://github.com/cjsheets/gatsby-plugin-typescript-scss-modules
- Owner: cjsheets
- Created: 2018-01-21T22:00:04.000Z (almost 7 years ago)
- Default Branch: master
- Last Pushed: 2018-06-30T15:22:26.000Z (over 6 years ago)
- Last Synced: 2024-10-20T07:44:16.264Z (about 1 month ago)
- Language: TypeScript
- Size: 40 KB
- Stars: 0
- Watchers: 2
- Forks: 1
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# Gatsby Plugin Typescript SCSS Modules
This [GatsbyJS](gatsbyjs.org) plugin facilitates the use of SCSS imports with TypeScript. Using this plugin, you can import an *.scss file and webpack will automatically generate typings.The code is a hybrid of [gatsby-plugin-typescript-css-modules
](https://github.com/jcreamer898/gatsby-plugin-typescript-css-modules) and Gatsbys [official SCSS plugin](https://github.com/gatsbyjs/gatsby/tree/master/packages/gatsby-plugin-postcss-sass).Ultimately, this is an extension of [typings-for-css-modules-loader](https://github.com/Jimdo/typings-for-css-modules-loader).
### Use
In my experience, this module requires node-sass and sass-loader to be dependencies of the gatsby project.
```bash
npm i gatsby-plugin-typescript-scss-modules
```Then, add the plugin to your `gatsby-config.js`...
```js
"gatsby-plugin-typescript-scss-modules"
]
```