Permalink
Browse files

webpack 0.10

  • Loading branch information...
1 parent 9a5bfef commit 39a0d796df9b522b7c9c0a75fe5792e1221aa0b6 @sokra sokra committed Mar 26, 2013
View
@@ -35,7 +35,8 @@ module.exports = function(grunt) {
module: {
loaders: [
{ test: /\.json$/, loader: "<%= 'json' %>" },
- { test: /\.css$/, loader: "style!css" }
+ { test: /\.css$/, loader: "style!css" },
+ { test: /\.coffee$/, loader: "coffee-loader" }
],
},
plugins: [
View
@@ -11,17 +11,18 @@
],
"homepage": "http://github.com/webpack/the-big-test",
"dependencies": {
- "webpack": "0.9.x",
- "webpack-dev-server": "0.9.x",
- "grunt": "~0.4.0rc7",
- "grunt-webpack": "0.9.x",
+ "webpack": "0.10.x",
+ "webpack-dev-server": "0.10.x",
+ "grunt": "~0.4.0",
+ "grunt-webpack": "0.10.x",
"chai": "1.4.x",
"enhanced-require": "0.5.x",
"mocha-loader": "0.5.x",
"coverjs-loader": "0.5.x",
+ "coffee-loader": "0.6.x",
"bundle-loader": "0.5.x",
- "imports-loader": "0.5.x",
- "exports-loader": "0.5.x",
+ "imports-loader": "0.6.x",
+ "exports-loader": "0.6.x",
"worker-loader": "0.5.x",
"json5-loader": "0.5.x",
"json-loader": "0.5.x"
@@ -0,0 +1,3 @@
+module.exports = function(value) {
+ return value;
+};
@@ -1,5 +1,7 @@
onmessage = function(event) {
- postMessage(event.data);
- if(typeof __$coverObject !== "undefined")
- postMessage(JSON.stringify(__$coverObject));
+ require(["./identitiy"], function(identitiy) {
+ postMessage(identitiy(event.data));
+ if(typeof __$coverObject !== "undefined")
+ postMessage(JSON.stringify(__$coverObject));
+ });
}
@@ -0,0 +1,4 @@
+i = 1 + 1;
+j = i + i;
+identity = (a) -> a
+module.exports = identity moduleA
View
@@ -7,6 +7,12 @@ describe("imports-loader", function() {
importModule.should.be.eql({ module: true });
});
+ it("should import a coffee-script module", function() {
+ var importModule = require("imports?moduleA!./imports-loader/import-test-file.coffee");
+ should.exist(importModule);
+ importModule.should.be.eql({ module: true });
+ });
+
it("should import a module with text", function() {
var importModule = require("imports?moduleA=moduleB!./imports-loader/import-test-file");
should.exist(importModule);
View
@@ -2,8 +2,9 @@ module.exports = {
entry: "mocha!./test/client-tests",
module: {
loaders: [
- { test: /\.json$/, loader: "json" },
- { test: /\.css$/, loader: "style!css" }
+ { test: /\.json$/, loader: "json-loader" },
+ { test: /\.css$/, loader: "style-loader!css-loader" },
+ { test: /\.coffee$/, loader: "coffee-loader" }
]
}
}

0 comments on commit 39a0d79

Please sign in to comment.