2.1.1 • Published 4 years ago

@hisystems/snowpack-plugin-babel v2.1.1

Weekly downloads
-
License
MIT
Repository
-
Last release
4 years ago

@hisystems/snowpack-plugin-babel

Use Babel to build your files from source. Automatically inherits from your local project .babelrc or babel.config.json files.

npm install --save-dev @hisystems/snowpack-plugin-babel
// snowpack.config.json
{
  "plugins": [
    [
      "@hisystems/snowpack-plugin-babel",
      {
        "input": ['.js', '.mjs', '.jsx', '.ts', '.tsx'], // (optional) specify files for Babel to transform
        transformOptions: {
          // babel transform options
        }
      }
    ]
  ]
}

Plugin Options

NameTypeDescription
inputstring[](optional) By default, Babel scans & transfoms these extensions: ['.js', '.jsx', '.ts', '.tsx']. Modify this array if you’d like to change this.
transformOptionsobject(optional) See https://babeljs.io/docs/en/options