JSPM

  • ESM via JSPM
  • ES Module Entrypoint
  • Export Map
  • Keywords
  • License
  • Repository URL
  • TypeScript Types
  • README
  • Created
  • Published
  • Downloads 3586
  • Score
    100M100P100Q122639F
  • License MIT

Google Closure Compiler plugin for Webpack

Package Exports

  • webpack-closure-compiler

This package does not declare an exports field, so the exports above have been automatically detected and optimized by JSPM instead. If any package subpath is missing, it is recommended to post an issue to the original package (webpack-closure-compiler) to support the "exports" field. If that is not possible, create a JSPM override to customize the exports field for this package.

Readme

webpack-closure-compiler

Google Closure Compiler plugin for Webpack

WIP

Installation

npm i -D webpack-closure-compiler

Usage

Compiles ES5 into ES5 in ADVANCED_OPTIMIZATIONS mode.

What to Watch Out for When Using ADVANCED_OPTIMIZATIONS

var path = require('path');
var ClosureCompilerPlugin = require('webpack-closure-compiler');

module.exports = {

    entry: [
        path.join(__dirname, 'app.js')
    ],
    module: {
        loaders: [
            { test: /\.js$/, exclude: /node_modules/, loaders: ['babel-loader?optional=runtime&stage=0&cacheDirectory'] }
        ]
    },
    output: {
        path: path.join(__dirname, '/'),
        filename: 'app.min.js'
    },
    plugins: [
        new ClosureCompilerPlugin()
    ]
};