-
-
Notifications
You must be signed in to change notification settings - Fork 478
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
feat(basic): prefer non global object of node #159
Conversation
I am not so sure. As we are using |
Your opinion is reasonable. I think, mounting Maybe we can ban the |
Just a quick question. From what I understand, |
Oh I didn't know, thanks. PR welcome to improve it! |
commit 5240f68 Author: Anthony Fu <anthonyfu117@hotmail.com> Date: Tue Apr 4 08:56:34 2023 +0200 chore: release v0.38.4 commit 79c8de5 Author: Anthony Fu <anthonyfu117@hotmail.com> Date: Tue Apr 4 08:56:29 2023 +0200 chore: update deps commit 3f13db7 Author: 曾明健 <hellozmj@qq.com> Date: Tue Apr 4 14:55:00 2023 +0800 refactor: remove `eslint-plugin-node` (antfu#162) commit 7a5daf6 Author: Anthony Fu <anthonyfu117@hotmail.com> Date: Mon Apr 3 17:19:24 2023 +0200 chore: update lock commit 79b63bc Author: Anthony Fu <anthonyfu117@hotmail.com> Date: Mon Apr 3 14:43:41 2023 +0200 chore: enable hoist commit 60002c3 Author: Anthony Fu <anthonyfu117@hotmail.com> Date: Mon Apr 3 14:42:06 2023 +0200 chore: release v0.38.3 commit 502f6b0 Author: 曾明健 <hellozmj@qq.com> Date: Mon Apr 3 20:41:41 2023 +0800 feat(basic): prefer non global object of node (antfu#159) Co-authored-by: Anthony Fu <anthonyfu117@hotmail.com> commit d1cd722 Author: 曾明健 <hellozmj@qq.com> Date: Mon Apr 3 20:30:54 2023 +0800 feat(basic): new line after import (antfu#161) commit d2150ee Author: Anthony Fu <anthonyfu117@hotmail.com> Date: Thu Mar 30 11:02:49 2023 +0200 fix(top-level-function): narrow warning range commit d3c3e1b Author: Anthony Fu <anthonyfu117@hotmail.com> Date: Thu Mar 30 10:57:04 2023 +0200 chore: update lock commit 3963633 Author: Anthony Fu <anthonyfu117@hotmail.com> Date: Thu Mar 30 10:53:40 2023 +0200 chore: release v0.38.2 commit e919334 Author: Anthony Fu <anthonyfu117@hotmail.com> Date: Thu Mar 30 10:53:36 2023 +0200 chore: format commit e8d73f7 Author: Anthony Fu <anthonyfu117@hotmail.com> Date: Thu Mar 30 10:51:35 2023 +0200 chore: release v0.38.1 commit 3a74c8e Author: Anthony Fu <anthonyfu117@hotmail.com> Date: Thu Mar 30 10:51:29 2023 +0200 fix(top-level-function): support async function commit 3fa8617 Author: Anthony Fu <anthonyfu117@hotmail.com> Date: Thu Mar 30 01:08:42 2023 +0200 test: add more test case commit ebbc1a7 Author: Anthony Fu <anthonyfu117@hotmail.com> Date: Wed Mar 29 15:52:45 2023 +0200 chore: rebuild lock file commit 417b60c Author: Anthony Fu <anthonyfu117@hotmail.com> Date: Wed Mar 29 15:47:19 2023 +0200 chore: release v0.38.0 commit 9768ccd Author: Anthony Fu <anthonyfu117@hotmail.com> Date: Wed Mar 29 15:47:03 2023 +0200 chore: update deps commit 87d26fb Author: Anthony Fu <anthonyfu117@hotmail.com> Date: Wed Mar 29 15:46:16 2023 +0200 feat: enforce to use function declaration on top-level commit e17d2f8 Author: Anthony Fu <anthonyfu117@hotmail.com> Date: Fri Mar 24 10:08:38 2023 +0100 docs: update commit 4ef978a Author: Anthony Fu <anthonyfu117@hotmail.com> Date: Fri Mar 24 10:01:44 2023 +0100 refactor: rename folders commit ab850b0 Author: Anthony Fu <anthonyfu117@hotmail.com> Date: Sat Mar 18 22:01:51 2023 +0100 chore: release v0.37.0 commit 7632765 Author: Anthony Fu <anthonyfu117@hotmail.com> Date: Sat Mar 18 22:01:39 2023 +0100 feat: upgrade deps, support typescript 5.0 commit d3c1119 Author: Ivan Demchuk <ivan.demchuk@gmail.com> Date: Thu Mar 16 12:34:58 2023 +0200 feat: enable `vue/no-unused-refs` (antfu#158)
Description
Ban using
Buffer
andprocess
object without import.Why: These two objects can only be used in Node. Browser and other runtime (like
Deno
) have no such objects. Before using them, if we haverequire
orimport
statement, we can quickly migrate the Node script to browser or Deno by replacing therequire('node:process')
to another object.If we don't enforce these rules, we have to check manually, like global searching.
Linked Issues
Additional context