azproduction / lmd

LMD - JavaScript Module-Assembler for building better web applications :warning: Project is no longer supported :warning:
http://azproduction.ru/lmd/
MIT License
449 stars 27 forks source link

String modules getting corrupted on Windows when using source map. #178

Closed FarSeeing closed 10 years ago

FarSeeing commented 10 years ago

If you have a string module, then in output file its LMD_TOKEN token is not removed when using source maps and building on Windows. It becomes like

"testModule": "/**[[LMD_TOKEN]]:D:\\www\\html\\test\\test.html**/Test",

It happens because string modules are actual string and Windows-style directory separator (\) gets escaped (\\) in contrary to plain modules. So when you search this token in code, it won't be found. Affected condition: https://github.com/azproduction/lmd/blob/master/bin/lmd_builder.js#L1451

azproduction commented 10 years ago

Thank you. Fixing.

azproduction commented 10 years ago

I have fixed this, but I can't publish package, because npm is unhealthy now. If this fix is important to you, you can install lmd from github on sha 0d75523eb210d5e775f6c88d2bc9a2a6e82fff5b. I will publish new package later.

azproduction commented 10 years ago

Fixed in lmd@1.11.6