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
fix(core): respect useDefineForClassFields tsconfig value #740
Merged
Brooooooklyn
merged 1 commit into
swc-project:master
from
inpart-io:fix-respect-tsconfig-usedefineforclassfields
Nov 14, 2023
Merged
fix(core): respect useDefineForClassFields tsconfig value #740
Brooooooklyn
merged 1 commit into
swc-project:master
from
inpart-io:fix-respect-tsconfig-usedefineforclassfields
Nov 14, 2023
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
dsyddall
force-pushed
the
fix-respect-tsconfig-usedefineforclassfields
branch
from
November 12, 2023 20:07
d183146
to
67f8082
Compare
Brooooooklyn
approved these changes
Nov 14, 2023
Brooooooklyn
changed the title
fix: respect useDefineForClassFields tsconfig value
fix(core): respect useDefineForClassFields tsconfig value
Nov 14, 2023
tsang-bot bot
added a commit
to tsangste/nx-package-test
that referenced
this pull request
Feb 6, 2024
This PR contains the following updates: | Package | Change | Age | Adoption | Passing | Confidence | |---|---|---|---|---|---| | [@swc-node/register](https://togithub.com/swc-project/swc-node) | [`1.6.8` -> `1.8.0`](https://renovatebot.com/diffs/npm/@swc-node%2fregister/1.6.8/1.8.0) | [![age](https://developer.mend.io/api/mc/badges/age/npm/@swc-node%2fregister/1.8.0?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![adoption](https://developer.mend.io/api/mc/badges/adoption/npm/@swc-node%2fregister/1.8.0?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![passing](https://developer.mend.io/api/mc/badges/compatibility/npm/@swc-node%2fregister/1.6.8/1.8.0?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![confidence](https://developer.mend.io/api/mc/badges/confidence/npm/@swc-node%2fregister/1.6.8/1.8.0?slim=true)](https://docs.renovatebot.com/merge-confidence/) | | [@swc/cli](https://togithub.com/swc-project/pkgs) ([source](https://togithub.com/node ./bin)) | [`0.3.5` -> `0.3.6`](https://renovatebot.com/diffs/npm/@swc%2fcli/0.3.5/0.3.6) | [![age](https://developer.mend.io/api/mc/badges/age/npm/@swc%2fcli/0.3.6?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![adoption](https://developer.mend.io/api/mc/badges/adoption/npm/@swc%2fcli/0.3.6?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![passing](https://developer.mend.io/api/mc/badges/compatibility/npm/@swc%2fcli/0.3.5/0.3.6?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![confidence](https://developer.mend.io/api/mc/badges/confidence/npm/@swc%2fcli/0.3.5/0.3.6?slim=true)](https://docs.renovatebot.com/merge-confidence/) | --- ### Release Notes <details> <summary>swc-project/swc-node (@​swc-node/register)</summary> ### [`v1.8.0`](https://togithub.com/swc-project/swc-node/releases/tag/%40swc-node/register%401.8.0) [Compare Source](https://togithub.com/swc-project/swc-node/compare/@swc-node/register@1.6.8...@swc-node/register@1.8.0) #### What's Changed - fix(core): remove `jsc.module.noInterop` when it's not supported by [@​kdy1](https://togithub.com/kdy1) in [swc-project/swc-node#733 - chore: fix README for install, build, and test by [@​devjiwonchoi](https://togithub.com/devjiwonchoi) in [swc-project/swc-node#728 - feat(register): @​swc-node/register/esm use TypeScript resolver by [@​cm-ayf](https://togithub.com/cm-ayf) in [swc-project/swc-node#727 - chore(deps-dev): bump [@​babel/traverse](https://togithub.com/babel/traverse) from 7.22.10 to 7.23.2 by [@​dependabot](https://togithub.com/dependabot) in [swc-project/swc-node#735 - Fix [#​716](https://togithub.com/swc-project/swc-node/issues/716) by [@​eliellis](https://togithub.com/eliellis) in [swc-project/swc-node#725 - chore(deps-dev): bump axios from 1.3.5 to 1.6.1 by [@​dependabot](https://togithub.com/dependabot) in [swc-project/swc-node#738 - fix(core): respect useDefineForClassFields tsconfig value by [@​dsyddall](https://togithub.com/dsyddall) in [swc-project/swc-node#740 - fix(core): respect sourceMaps swcrc value by [@​dsyddall](https://togithub.com/dsyddall) in [swc-project/swc-node#742 - feat: add esm-register for node>20.6 by [@​yeliex](https://togithub.com/yeliex) in [swc-project/swc-node#748 - chore(deps-dev): bump follow-redirects from 1.15.2 to 1.15.4 by [@​dependabot](https://togithub.com/dependabot) in [swc-project/swc-node#747 - feat(core): support swc's `ignoreDynamic` option by [@​SukkaW](https://togithub.com/SukkaW) in [swc-project/swc-node#745 - fix: fix import ts from node_modules by [@​yeliex](https://togithub.com/yeliex) in [swc-project/swc-node#744 - Mention --enable-source-maps in README.md for esm projects. by [@​Xinkai](https://togithub.com/Xinkai) in [swc-project/swc-node#737 - feat: upgrade dependencies by [@​Brooooooklyn](https://togithub.com/Brooooooklyn) in [swc-project/swc-node#751 #### New Contributors - [@​devjiwonchoi](https://togithub.com/devjiwonchoi) made their first contribution in [swc-project/swc-node#728 - [@​cm-ayf](https://togithub.com/cm-ayf) made their first contribution in [swc-project/swc-node#727 - [@​eliellis](https://togithub.com/eliellis) made their first contribution in [swc-project/swc-node#725 - [@​dsyddall](https://togithub.com/dsyddall) made their first contribution in [swc-project/swc-node#740 - [@​SukkaW](https://togithub.com/SukkaW) made their first contribution in [swc-project/swc-node#745 - [@​Xinkai](https://togithub.com/Xinkai) made their first contribution in [swc-project/swc-node#737 **Full Changelog**: https://github.com/swc-project/swc-node/compare/[@​swc-node/core](https://togithub.com/swc-node/core)[@​1](https://togithub.com/1).10.5...[@​swc-node/register](https://togithub.com/swc-node/register)[@​1](https://togithub.com/1).8.0 </details> --- ### Configuration 📅 **Schedule**: Branch creation - At any time (no schedule defined), Automerge - At any time (no schedule defined). 🚦 **Automerge**: Enabled. ♻ **Rebasing**: Whenever PR becomes conflicted, or you tick the rebase/retry checkbox. 👻 **Immortal**: This PR will be recreated if closed unmerged. Get [config help](https://togithub.com/renovatebot/renovate/discussions) if that's undesired. --- - [ ] <!-- rebase-check -->If you want to rebase/retry this PR, check this box --- This PR has been generated by [Renovate Bot](https://togithub.com/renovatebot/renovate). <!--renovate-debug:eyJjcmVhdGVkSW5WZXIiOiIzNy4xNzEuMCIsInVwZGF0ZWRJblZlciI6IjM3LjE3Mi4yIiwidGFyZ2V0QnJhbmNoIjoiZGV2ZWxvcCJ9--> Co-authored-by: tsang-bot[bot] <146107447+tsang-bot[bot]@users.noreply.github.com>
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Fixes #739
Currently,
useDefineForClassFields
is not read fromtsconfig.json
and not set in the SWC config.This PR updates the
tsCompilerOptionsToSwcConfig
function to read the value ofuseDefineForClassFields
fromtsconfig.json
(using the default value based ontarget
as specified at https://www.typescriptlang.org/tsconfig#useDefineForClassFields)See: https://swc.rs/docs/configuration/compilation#jsctransformusedefineforclassfields