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

fix(eslint-plugin): cache access to NODE_ENV #2693

Merged
merged 1 commit into from
Sep 21, 2023

Conversation

tido64
Copy link
Member

@tido64 tido64 commented Sep 21, 2023

Description

Cache access to NODE_ENV. process.env is apparently a special object and is slow to access. We don't expect NODE_ENV to change here, so we should cache it.

Test plan

n/a

@github-actions github-actions bot added the feature: eslint This is related to ESLint label Sep 21, 2023
Copy link
Contributor

@kelset kelset left a comment

Choose a reason for hiding this comment

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

I don't even know how you managed to figure this one out but :shipit:

@tido64
Copy link
Member Author

tido64 commented Sep 21, 2023

I don't even know how you managed to figure this one out but :shipit:

😅 Someone else did the work: jestjs/jest#14455

@tido64 tido64 enabled auto-merge (squash) September 21, 2023 08:57
@tido64 tido64 merged commit a442ffd into main Sep 21, 2023
12 checks passed
@tido64 tido64 deleted the tido/eslint-plugin/cache-node-env branch September 21, 2023 09:12
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
feature: eslint This is related to ESLint
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants