Last active
February 8, 2016 20:08
-
-
Save IngwiePhoenix/7d4fb5cbd70614f496d6 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
var html = require("./basic.html") | |
console.log(html); |
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
<!DOCTYPE html> | |
<html> | |
<head> | |
<!-- ... --> | |
</head> | |
<body> | |
Here is my pretty avatar! | |
<img src="./IngwiePhoenix.png"> | |
</body> | |
</html> |
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
module.exports = { | |
entry: "./app.js", | |
output: { | |
filename: "[name].js", | |
path: "./out" | |
}, | |
module: { | |
loaders: [ | |
{ | |
test: /\.png$/, | |
loaders: [ | |
// I know that my avatar is 14kb of size. | |
// Setting limit to 0 causes it to be inlined. | |
// Try setting it to something like 1024*15 :) | |
"url?limit=0", | |
// Standard options for image-loader...not going to go too fancy. | |
"image-webpack" | |
] | |
}, { | |
test: /\.html$/, | |
loader: "html" | |
} | |
] | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment