diff --git a/index.js b/index.js index e869e1d..1cc117a 100644 --- a/index.js +++ b/index.js @@ -34,9 +34,9 @@ var CreateFilePlugin = (function () { const createFile = () => _createFile(this.options.path, this.options.fileName, this.options.content); if (!!compiler.hooks) { - compiler.hooks.done.tap('CreateFileWebpack', createFile()); + compiler.hooks.afterPlugins.tap('CreateFileWebpack', createFile()); } else { - compiler.plugin('done', createFile()); + compiler.plugin('after-plugins', createFile()); } };