🚀 Socket Launch Week Day 5:Introducing Repository Access Permissions and Custom Roles.Learn more
Sign In

mika-pack-plugin

Package Overview
Dependencies
Maintainers
1
Versions
6
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

mika-pack-plugin - npm Package Compare versions

Comparing version
1.0.0
to
1.0.1
+1
-1
package.json
{
"name": "mika-pack-plugin",
"version": "1.0.0",
"version": "1.0.1",
"author": "daryl",

@@ -5,0 +5,0 @@ "scripts": {

@@ -1,43 +0,19 @@

// import { version } from '../package.json';
class MyExampleWebpackPlugin {
// 定义 `apply` 方法
apply(compiler) {
// 指定要追加的事件钩子函数
compiler.hooks.compile.tapAsync(
'afterCompile',
(compilation, callback) => {
console.log('mika kira kira bling bling ~');
console.log('Here’s the `compilation` object which represents a single build of assets:', compilation);
// export default function () {
// console.log('version ' + version);
// }
// export default function () {
// import('./extra.js').then(({ default: foo }) => console.log(foo));
// }
// const extra = require('./extra.js')
// 使用 webpack 提供的 plugin API 操作构建结果
compilation.addModule(/* ... */);
// module.exports = {
// goTheHell,
// extra
// }
// export default {
// goTheHell,
// callFuck:()=>{
// console.log('ocena')
// }
// }
const ddd = {
a:123,
n:333
callback();
}
);
}
}
// export {
// ddd as default,
// goTheHell,
// goTheHellArk
// }
function HelloWorldPlugin(options) {
// Setup the plugin instance with options...
}
HelloWorldPlugin.prototype.apply = function(compiler) {
compiler.plugin('done', function() {
console.log('Hello World! mika kira~');
});
};
module.exports = HelloWorldPlugin;
module.exports = MyExampleWebpackPlugin;