Skip to content

Instantly share code, notes, and snippets.

@potato4d
Last active February 21, 2017 00:37
Show Gist options
  • Save potato4d/6358e4d0162d1b8ba2399c188914476f to your computer and use it in GitHub Desktop.
Save potato4d/6358e4d0162d1b8ba2399c188914476f to your computer and use it in GitHub Desktop.
英語資料を読むのが面倒な人のためのwebpack 2移行ガイド ref: http://qiita.com/potato4d/items/4975c3d9c5fe56fa78c1
const services = []
const serviceList = ["serviceA", "serviceB", "serviceD"];
serviceList.map((s)=>{
System.import("./services/" + s)
.then((mod)=>{
services.push(mod);
})
});
$ rm -Rf ./node_modules/
import "./file_b" // これで動く
file_b("hoge")
export default function(word){console.log(word)}
module.exports = {
module: {
rules: [
{
test: /\.css/,
use: "css-loader"
}
]
}
}
module.exports ={
module: {
loaders: [
{
test: /\.css/,
use: "css"
}
]
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment