question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Source map support

See original GitHub issue

I found good feature in linaria. Source map support should not be so hard if Babel gives you a position for a literal node.

We need:

  1. Take source-map (0.7 use async API, if it is a problem, using 0.6 is OK. I still use 0.6 in PostCSS, because we can’t use async API in few places)
  2. For every literal tag generator.addMapping.
  3. In the end, generate source map, encode it to data:uri and add to CSS file.

Issue Analytics

  • State:open
  • Created 5 years ago
  • Comments:8 (3 by maintainers)

github_iconTop GitHub Comments

1reaction
aicommented, Oct 2, 2018

Also here is the best tool to debug source maps:

https://sokra.github.io/source-map-visualization/

1reaction
aicommented, Oct 2, 2018

O neat so at least in PostCSS it will update the source maps it finds after it compiles?

Yeap. I think Sass could update it too even without previous source map support, since (as I think) webpack merge source map by it own. Loaders just return own source maps and webpack merge them.

Read more comments on GitHub >

github_iconTop Results From Across the Web

source-map-support - npm
This module provides source map support for stack traces in node via the V8 stack trace API. It uses the source-map module to...
Read more >
Is there source map support for typescript in node / nodemon?
My tsconfig has sourceMap set to true and the *.map.js files are generated. When I execute my transpiled *.js JavaScript files via node...
Read more >
Source map support - APM Node.js Agent - Elastic
The Elastic APM Node.js agent supports source maps by default. If you transpile your source code and supply a source map, the agent...
Read more >
Source maps in Node.js. Supporting the many flavors of…
Source maps provide a method for translating from generated source back to the original, via meta-information attached to the generated source; ...
Read more >
node_modules/source-map-support - Gitlab inria
This module provides source map support for stack traces in node via the V8 stack trace API. It uses the source-map module to...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found