0.1.4 • Published 5 years ago

yml-to-scss-loader v0.1.4

Weekly downloads
1
License
MIT
Repository
-
Last release
5 years ago

yml-to-scss-loader is a webpack loader which translates yml settings files into scss and json. The purpose is to have the config in one single place and be able to use it in scss and js, react or vue apps.

This could be useful especially for component props validation automation.

Install

Install with npm:

$ npm install --save-dev yml-to-scss-loader

Install with yarn:

$ yarn add yml-to-scss-loader

Install with bower

$ bower install yml-to-scss-loader --save

##Usage:

in your webpack config add the following rule, replacing the vars with your own settings:

module: {
  rules: [{
    test: /\.yml?$/,
    use: {
      loader: 'yml-to-scss-loader',
      options: {
        output: [path-to-json-and-scss-files],
        scss: true,
        json: true
      }
    },
    exclude: [
      /(node_modules)/
    ]
  }]
}

##License

MIT © Catalin Nita

0.1.4

5 years ago

0.1.3

5 years ago

0.1.2

5 years ago

0.1.1

5 years ago

0.1.0

5 years ago

0.0.1

5 years ago