Skip to content
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

Allow disabling sourcemap support #470

Merged
merged 2 commits into from Mar 18, 2018
Merged

Allow disabling sourcemap support #470

merged 2 commits into from Mar 18, 2018

Conversation

kulshekhar
Copy link
Owner

closes #469

@kulshekhar kulshekhar merged commit b4628f0 into master Mar 18, 2018
@kulshekhar kulshekhar deleted the sms-flag branch March 18, 2018 21:31
@chrisfarms
Copy link

Less than one hour from report to release ... 💯

Looks good! ... I can confirm that the new disableSourceMapSupport resolves the issues I was seeing with incorrect line numbers in stack traces. Thanks for that!

@kulshekhar
Copy link
Owner Author

Less than one hour from report to release

haha, yeah. I was going through the code to see what parts can be trimmed off when I saw your post. It seemed like taking one step closer to removing sourcemap-support related stuff from ts-jest (jest provides it)

@sinbargit
Copy link

does injectSourcemapHook still work now?

@ahnpnl
Copy link
Collaborator

ahnpnl commented Apr 29, 2021

no that option doesn't exist with current version. That was before 23.10.

@ahnpnl
Copy link
Collaborator

ahnpnl commented Apr 29, 2021

To disable source map, you can go to node_modules/ts-jest/dist/config/config-set.js, look for this._overriddenCompilerOptions and set sourceMap: false. After that, clear jest cache and rerun test to get it affected

@sinbargit
Copy link

the ts-jest not compatible with sourceMap:false. If just hack that flag will cause other error.
image

@ahnpnl
Copy link
Collaborator

ahnpnl commented Apr 29, 2021

ye it requires some code changes, not only change that flag, see #2544 which will be included in next tag for now. Later it will be available in v27

@ahnpnl
Copy link
Collaborator

ahnpnl commented Apr 30, 2021

The PR is merged but not released yet :)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Add a global config flag to disable sourcemap-support injection
4 participants