-
Notifications
You must be signed in to change notification settings - Fork 30
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
perf: Cherry-pick Lodash imports for smaller bundles #2870
Conversation
0071d2e
to
ef0343d
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
- I love this
- what do you think about adding
eslint-plugin-lodash
and linting this, so it doesn't get reversed in the future?
in the root .eslintrc.json
{
...
"files": ["*.ts", "*.tsx", "*.js", "*.jsx"],
"plugins": ["lodash"],
"rules": {
"lodash/import-scope": ["error", "method-package"],
...
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
🥲
ooh, yes I'll add that! |
f1f5dfe
to
4bbac12
Compare
files: ['*.ts', '*.tsx', '*.js', '*.jsx'], | ||
plugins: ['lodash'], | ||
rules: { | ||
'lodash/import-scope': ['error', 'method'], |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I used method
rather than method-package
here for lodash/map
rather than lodash.map
📬Published Alpha Packages:@codecademy/[email protected] |
🚀 Styleguide deploy preview ready! |
Overview
Use Cherry-picked Lodash imports for smaller bundles
PR Checklist
Related to designs:Related to JIRA ticket: [ABC-123]This PR includes unit tests for the code changeThis PR includes testing instructions tests for the code changePR Links and Envs