Last active
December 28, 2016 02:40
-
-
Save jdb8/41f3c0394b8af8652b2528aa20fd883f to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
export const hi = 'foo'; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
function HelloWorldPlugin(options) {} | |
HelloWorldPlugin.prototype.apply = function(compiler) { | |
compiler.plugin('emit', function(compilation, callback) { | |
delete compilation.assets['output.js']; | |
callback(); | |
}); | |
}; | |
module.exports = HelloWorldPlugin;i |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import hi from './foo.js'; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
var HelloWorldPlugin = require('./hello-world-plugin.js'); | |
module.exports = { | |
entry: './index.js', | |
output: { | |
path: 'dist', | |
filename: 'output.js' | |
}, | |
plugins: [ | |
new HelloWorldPlugin(), | |
] | |
}; |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment