mirror of
https://github.com/less/less.js.git
synced 2026-01-23 14:18:00 -05:00
Base64 encode source maps
This prevents some edge cases where encodeURIComponent fails to create a valid source map. This particular edge case was identified when trying to create source maps for the lesshat mixin library. Signed-off-by: Tim Smart <tim.smart@designworks.co.nz>
This commit is contained in:
@@ -127,7 +127,7 @@
|
||||
if (this._writeSourceMap) {
|
||||
this._writeSourceMap(sourceMapContent);
|
||||
} else {
|
||||
sourceMapURL = "data:application/json," + encodeURIComponent(sourceMapContent);
|
||||
sourceMapURL = "data:application/json;base64," + require('./encoder.js').encodeBase64(sourceMapContent);
|
||||
}
|
||||
|
||||
if (sourceMapURL) {
|
||||
|
||||
Reference in New Issue
Block a user