razzle-plugin-disable-sourcemaps-production

1.0.0 • Public • Published

Razzle Plugin Disable Sourcemaps Production

This package contains a plugin to disable Sourcemaps CSS and JS on Production build with Razzle.

Usage in Razzle Projects

  • Install razzle-plugin-disable-sourcemaps-production

    if you're using yarn

    yarn add razzle-plugin-disable-sourcemaps-production --dev
    

    if you're using npm

    npm install razzle-plugin-disable-sourcemaps-production --save-dev
    
  • create a razzle.config.js file in root directory of project (next to the package.json) and put this content inside it

    // razzle.config.js
    module.exports = {
      plugins: [
        'disable-sourcemaps-production'
      ],
    };
    

Options

  • devtool (default: cheap-module-eval-source-map)
    You can change the devtool on Development mode with the option devtool, but will be disable on Production:

    // razzle.config.js
    module.exports = {
      plugins: [
        {
          name: 'disable-sourcemaps-production',
          options: {
            devtool: 'eval'
          }
        }
      ],
    };
    

See Webpack Devtool Docs for more information.

Package Sidebar

Install

npm i razzle-plugin-disable-sourcemaps-production

Weekly Downloads

87

Version

1.0.0

License

MIT

Unpacked Size

3.81 kB

Total Files

4

Last publish

Collaborators

  • finmavis