Explorar el Código

Video 10: plugins introduction.

Frederic G. MARAND hace 4 años
padre
commit
fb193e4775
Se han modificado 1 ficheros con 10 adiciones y 0 borrados
  1. 10 0
      ExamplePlugin.js

+ 10 - 0
ExamplePlugin.js

@@ -0,0 +1,10 @@
+class ExamplePlugin {
+  apply(compiler) {
+    compiler.plugin("run", (compiler, callback) => {
+      console.log("Webpack is running our plugin");
+      callback();
+    });
+  }
+}
+
+module.exports = ExamplePlugin;