-
Notifications
You must be signed in to change notification settings - Fork 71
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
when tsconfig specifies inlineSourceMap: true
then no sourcemap is generated
#71
Comments
To be clear, I have a reasonable workaround. I'd only like it to be less difficult to discover. At a minimum, this issue should help others find it... |
|
My use case is developer mode with rollup:
With @ezolenko care to elaborate why forcing |
@lolgesten Rollup handles sourcemaps (as other plugins on-chain can further change them), so it makes more sense that related Does setting |
@agilgur5 sorry i don't have my test setup anymore. We decided to go with esbuild in the end. |
@lolgesten thanks for the quick response anyway! Your comment got some upvotes and this issue is linked in the README, so thought it would be good to respond even if it were ~2 years old. Hopefully my response will help another reader in the future! |
What happens and why it is wrong
in my tsconfig.json I have
inlineSourceMap: true
. I also configured rollup to usesourcemap: 'inline'
. Rollup builds occur without issue, but my resultant .js file contained an inline sourcemap for non-ts assets only. After much experimentation I found that I can re-enable sourceMaps for TS with the following configuration:This is not intuitive. I've already expressed that I want sourcemaps, and that I want rollup to generate an inline sourcemap. The plugin should ideally respect the
inlineSourceMap
option intsconfig.json
.If this is not feasible [likely because it's hard to scrape out inline source maps from tsc output] then there should be an error displayed and rollup should fail, telling the user they must disable
inlineSourceMap
and enablesourceMap
in their typescript overrides.Environment
Not relevant
Versions
rollup.config.js
I'm only including the relevant portion.
Original:
With Workaround:
tsconfig.json
The text was updated successfully, but these errors were encountered: