@@ -15,22 +15,22 @@ module.exports.pitch = function (request) {
1515 var options = loaderUtils . getOptions ( this ) || { } ;
1616
1717 validateOptions ( require ( './options.json' ) , options , 'Style Loader' )
18-
18+
1919 options . hmr = typeof options . hmr === 'undefined' ? true : options . hmr ;
2020
21- // The variable is needed, because the function should be inlined.
21+ // The variable is needed, because the function should be inlined.
2222 // If is just stored it in options, JSON.stringify will quote
2323 // the function and it would be just a string at runtime
2424 var insertInto ;
25-
26- if ( typeof options . insertInto === "function" ) {
27- insertInto = options . insertInto . toString ( ) ;
25+
26+ if ( typeof options . insertInto === "function" ) {
27+ insertInto = options . insertInto . toString ( ) ;
2828 }
29-
30- // We need to check if it a string, or variable will be "undefined"
29+
30+ // We need to check if it a string, or variable will be "undefined"
3131 // and the loader crashes
32- if ( typeof options . insertInto === "string" ) {
33- insertInto = '"' + options . insertInto + '"' ;
32+ if ( typeof options . insertInto === "string" ) {
33+ insertInto = '"' + options . insertInto + '"' ;
3434 }
3535
3636 var hmr = [
@@ -79,11 +79,11 @@ module.exports.pitch = function (request) {
7979 "var transform;" ,
8080 "var insertInto;" ,
8181 "" ,
82- options . transform ? "transform = require(" + loaderUtils . stringifyRequest ( this , "!" + path . resolve ( options . transform ) ) + ");" : "" ,
83- "" ,
82+ options . transform ? "transform = require(" + loaderUtils . stringifyRequest ( this , "!" + path . resolve ( options . transform ) ) + ");" : "" ,
83+ "" ,
8484 "var options = " + JSON . stringify ( options ) ,
8585 "" ,
86- "options.transform = transform" ,
86+ "options.transform = transform" ,
8787 "options.insertInto = " + insertInto + ";" ,
8888 "" ,
8989 // Add styles to the DOM
0 commit comments