Skip to content
This repository has been archived by the owner on Feb 8, 2024. It is now read-only.

Docs: update for PR #13/#14 #15

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

SukkaW
Copy link
Contributor

@SukkaW SukkaW commented Dec 23, 2021

No description provided.

@SukkaW SukkaW changed the title Docs: update for PR #14 Docs: update for PR #13/#14 Dec 23, 2021
Comment on lines +19 to 28
```js
require("@swc/register")({
extensions: [],
ignore: [],
only: [],
// And swc configuration
jsc: {},
env: {}
});
```
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

As the automatic hook is being removed in #14, @swc/register always requires an option. It is to match the behavior of @babel/register.

Comment on lines -25 to -27
```bash
swc-node <filename>
node -r '@swc/register' <filename>
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

As the automatic hook is being removed in #14, node -r '@swc/register' is no longer supported.

Babel has a dedicated package @babel/node (node -r @swc/node). swc should use a dedicated package, too.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

As the automatic hook is being removed in #14, node -r '@swc/register' is no longer supported.
Babel has a dedicated package @babel/node (node -r @swc/node). swc should use a dedicated package, too.

This does mean we need a custom CLI?
While reading again before merging into the main repository, I found that this package would be useless.

@SukkaW
Copy link
Contributor Author

SukkaW commented Dec 23, 2021

Note, that #13 and #14 introduce some Breaking Changes (in order to match the behavior of @babel/register). A major version bumped will be required.

@SukkaW
Copy link
Contributor Author

SukkaW commented Dec 23, 2021

And another suggestion. Since #13 & #14 require a major version bump, maybe it is a chance to archive the repo and move register as a monorepo under swc.

@kdy1
Copy link
Member

kdy1 commented Dec 24, 2021

Yeah, I think I should move it to swc main repository. Thank you!

SeiwonPark referenced this pull request in SeiwonPark/zigoom Nov 27, 2023
Since @swc/register has depdency for version 1.3.78

And another versions fall in error

+ This would be moved (#https://github.com/swc-project/register/pull/15\#issuecomment-1000662003)
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Development

Successfully merging this pull request may close these issues.

3 participants