Souhaieb Besbes
Souhaieb Besbes

Reputation: 1504

Web Essentials 2015 JavaScript source map not generated

Web Essentials is supposed to automatically generate source map files for JavaScript minified files as stated here on the project website.

However, for my minified files, I find only the sourcename.min.js file. The web site states that the option should be in Tools/Options, however I can't seem to find any related toggle to enable that feature under the Web Essentials node.

What am I missing here? Is there any work-around to enable the feature?

Upvotes: 2

Views: 1455

Answers (2)

Rodan Sotto
Rodan Sotto

Reputation: 51

To enable source maps, add this property to the bundleconfig.json file:

"sourceMap": true

It says here in this link: https://marketplace.visualstudio.com/items?itemName=MadsKristensen.BundlerMinifier, under Source maps section.

Upvotes: 0

Dan Overlander
Dan Overlander

Reputation: 306

I think what you want has been moved into the "Bundler and Compiler" extension. Although you are correct in that the Web Essentials project website says map files can be generated, I think the site is out of date. Check out what is said at https://visualstudiogallery.msdn.microsoft.com/9ec27da7-e24b-4d56-8064-fd7e88ac1c40 where they talk about map files. It does say they're supposed to be autogenerated, but for my concerns (I wanted CSS map files generated) I had to modify the bundleconfig.json as described at the bottom of that page.

Upvotes: 1

Related Questions