New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
source maps are off by 3 lines #410
Comments
No, this is the first time I heard about this. |
I'll get back to this once I have a reproduction case. |
Are you using any transforms? I had a similar issue, but realized that it was from a transform that actually added several lines of code. Just a thought... |
Since browserify will consume existing source maps and adjust them to account for the file's position inside the bundle, if the original source map is off, that couldn't be corrected. If a transform is adding lines to a file without adjusting source maps if they exist, that could also be an issue. In that case I'd suggest to either fix that transform to stop doing that (i.e. put it on same line with semicolons separating statements) or don't use that transform. I doubt though that @Raynos is using a transpiler so the problem may lie elsewhere. |
Oh wait. I do prefix like 3 lines of code at the top of my file for (function () {
window.NODE_ENV = {{process.env.NODE_ENV}}
})() |
@Raynos that's pretty funny. Two options:
|
I removed my new lines. |
I'm using browserify2 on a large project and the source map break points seem to be off by 3 lines for some reason.
Is this a known issue?
The text was updated successfully, but these errors were encountered: