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

🔧 Update React imports #859

Merged
merged 4 commits into from
Nov 10, 2020
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 7 additions & 1 deletion .eslintrc.js
Original file line number Diff line number Diff line change
@@ -1,3 +1,9 @@
const pkg = require('./libraries/core-react/package.json')

const {
devDependencies: { react: reactVersion },
} = pkg

module.exports = {
root: true,
extends: [
Expand Down Expand Up @@ -25,7 +31,7 @@ module.exports = {
},
settings: {
react: {
version: 'detect',
version: reactVersion,
Copy link
Member Author

Choose a reason for hiding this comment

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

This setting was set to 'detect' which did not work because React is not installed in the root. Eslint then guesses that we’re using the latest version of React, which worked fine up until React 17. The only drawback from fetching the version from the core-react package, is that we now assume we’re using the same version of React in all the projects.

},
},
globals: {
Expand Down
2 changes: 1 addition & 1 deletion apps/figma-broker/pnpm-lock.yaml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Loading