Commit Graph

159 Commits

Author SHA1 Message Date
Jan Nicklas 2dbf2222bd Bump version to 2.0.2 2015-09-09 11:49:01 +02:00
Jan Nicklas f16dc48025 Fix minify and head injection 2015-09-09 11:46:22 +02:00
Kees Kluskens 668ab7ffb3 Bring back template path regex.
This is untested code!
2015-09-09 11:38:25 +02:00
Kees Kluskens 2c028a95c0 Add test for loader errors and fix other broken tests.
test.html used the old blueimp template syntax; but because `inject` was
switched to `true` the tests still passed.
2015-09-09 11:38:25 +02:00
Kees Kluskens 0ede95051b Remove manifest option again and update test. 2015-09-09 11:38:25 +02:00
Kees Kluskens cfb7e3f01f Test that the template option picks up a loader from the webpack config. 2015-09-09 11:38:25 +02:00
Kees Kluskens 706267961f Add underscore test template. 2015-09-09 11:38:24 +02:00
Kees Kluskens 648fd72c22 Fix manifest option and add tests. 2015-09-09 11:38:24 +02:00
Kees Kluskens 989a09f97a Add loader tests and cleanup redundant code. 2015-09-09 11:38:24 +02:00
Kees Kluskens 55fcb6d939 Fix displaying loader errors. 2015-09-09 11:38:24 +02:00
Simen Bekkhus d3eed761f7 Return minified html from promise 2015-09-09 11:38:24 +02:00
Jan Nicklas 9cb8dfa3aa Fix rebase typo 2015-09-09 11:38:24 +02:00
Mate Olah a1ed078135 Bump project dependencies. 2015-09-09 11:38:24 +02:00
Jan Nicklas 85c5ac0446 Fix two-loaders example 2015-09-09 11:38:24 +02:00
Jan Nicklas dd3244de6f Simplify jade demo 2015-09-09 11:38:24 +02:00
Jan Nicklas ef42642f34 Add jade-loader example 2015-09-09 11:38:24 +02:00
Jan Nicklas 54002dd271 Add more verbose syntax error messages 2015-09-09 11:38:23 +02:00
Jan Nicklas b34ef76b04 Fix example paths 2015-09-09 11:38:23 +02:00
Jan Nicklas b0af6a3d42 More verbose error messages 2015-09-09 11:38:23 +02:00
Jan Nicklas 2365ded8da Pre release 2.0 2015-09-09 11:38:23 +02:00
Jan Nicklas ea6c4ded4a Fix demos 2015-09-09 11:38:07 +02:00
Jan Nicklas 6b59214353 Cache loader result 2015-09-09 11:38:07 +02:00
Jan Nicklas 387ca2448a Use lodash to solve dependency issues for the fallback loader 2015-09-09 11:38:07 +02:00
Jan Nicklas 931ed64467 Fix correct autoloading 2015-09-09 11:38:07 +02:00
Jan Nicklas a8677988bd Fix rebase 2015-09-09 11:38:07 +02:00
Jan Nicklas 39cfc493a0 Refactor examples 2015-09-09 11:38:07 +02:00
Jan Nicklas 02223b29e5 Use blueimp loader instead of blueimp 2015-09-09 11:38:07 +02:00
Jan Nicklas 181b026946 Fix webpack-dev-server child compilation on template change 2015-09-09 11:38:06 +02:00
Jan Nicklas ed8f61fc69 Fix chunk filtering 2015-09-09 11:38:06 +02:00
Jan Nicklas e52bf5e2f3 Refactor template loading 2015-09-09 11:38:06 +02:00
Kenny Tran c7225f7abb Fix typo 2015-09-09 11:38:06 +02:00
Jan Nicklas f1d3d95af6 Move compilation into a new function 2015-09-09 11:38:06 +02:00
Jan Nicklas faf4e764d4 Fix image example 2015-09-09 11:38:06 +02:00
Jan Nicklas ed8e4b290f Fix to resolve path of modules 2015-09-09 11:38:06 +02:00
Jan Nicklas d82bd52e2f Add minification again 2015-09-09 11:38:06 +02:00
Jan Nicklas c8a69255b9 Refactoring to support loaders 2015-09-09 11:38:06 +02:00
Jan Nicklas f68b6e3783 Merge pull request #81 from SimenB/patch-1
Passing true to minify does nothing
2015-08-15 14:04:37 +02:00
Simen Bekkhus 909b811d70 Passing true to minify does nothing
All `html-minifier` options are `false` by default, so passing just true does nothing to the output
2015-08-14 08:59:43 +02:00
Jan Nicklas 95feed96ba Bump version 2015-08-04 17:15:30 +02:00
Jan Nicklas c5d1a8e36e Merge pull request #74 from tlrobinson/master
Fixes stylesheet <link>s being discarded when used with "inject: 'head'"
2015-08-03 23:13:34 +02:00
Tom Robinson 562acca036 Fixes stylesheet <links> being discarded when used with "inject: 'head'". 2015-07-29 11:23:10 -07:00
Jan Nicklas df09669ef5 Merge pull request #70 from mateatslc/master
Bump project dependencies
2015-07-16 16:04:21 +02:00
Mate Olah d2f767176c Bump project dependencies. 2015-07-16 15:43:27 +02:00
Jan Nicklas 89af128acf Merge pull request #69 from shprink/patch-1
Adding the file size to the chunk object
2015-07-13 11:59:23 +02:00
Julien Renaux dfb4f57179 Adding the file size to the chunk object
As far as I know, getting the file size within the template is not possible.

The file size is important in my case in order to have a progress loader via http request so I can do somehting like that:

```
function ajax(url, onProgress, callback, data, x) {
            try {
                x = new(this.XMLHttpRequest || ActiveXObject)('MSXML2.XMLHTTP.3.0');
                x.open(data ? 'POST' : 'GET', url, 1);
                x.setRequestHeader('X-Requested-With', 'XMLHttpRequest');
                x.setRequestHeader('Content-type', 'application/x-www-form-urlencoded');
                x.onreadystatechange = function() {
                    x.readyState > 3 && callback && callback(x.responseText, x);
                };
                x.addEventListener("progress", onProgress, false);
                x.send(data)
            } catch (e) {
                window.console && console.log(e);
            }
        };

        function onLoad(responseText) {
            var script = document.createElement('script');
            script.setAttribute('type', 'text/javascript');
            if (script.text) {
                script.text = content; // IE
            } else {
                script.appendChild(document.createTextNode(responseText));
            }
            document.getElementsByTagName('head')[0].appendChild(script);
            document.getElementById('appLoader').className = 'finished';
        }

        function onProgress(e) {
            var progress = Math.floor((e.loaded / {%=o.htmlWebpackPlugin.files.chunks.main.size %} || 0) * 100);
            document.getElementById('appLoader').setAttribute("value", progress);
            document.getElementById('appLoaderPercent').innerText = document.createTextNode(progress).textContent;
        }

        ajax('./{%=o.htmlWebpackPlugin.files.chunks.main.entry %}', onProgress, onLoad);
```
2015-07-13 11:43:18 +02:00
Jan Nicklas c630d339c6 Bump version 2015-07-08 11:27:09 +02:00
Jan Nicklas cdd563e5af Merge pull request #66 from cesarandreu/patch-1
Fix example template
2015-06-30 08:57:42 +02:00
Cesar Andreu 7200791f3b Fix example template 2015-06-29 18:30:21 -07:00
Jan Nicklas 55b530ba3f Support placing templates in subfolders 2015-06-29 15:57:18 +02:00
Jan Nicklas 266d8e2325 Merge pull request #62 from oliviertassinari/async
[async] make sure the async chunks aren't included in the html
2015-06-15 23:38:07 +02:00