Skip to content

chore: Scaffold Core repo #1006

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

Merged
merged 4 commits into from
Aug 31, 2023
Merged

chore: Scaffold Core repo #1006

merged 4 commits into from
Aug 31, 2023

Conversation

krizzu
Copy link
Member

@krizzu krizzu commented Aug 30, 2023

Summary

A basic setup for Core repo. Typescript and Eslint config are in roots, extended by workspaces.

@krizzu krizzu requested a review from tido64 August 30, 2023 21:30
Comment on lines +1 to +7
{
"tabWidth": 2,
"semi": true,
"singleQuote": true,
"bracketSpacing": true,
"parser": "typescript"
}
Copy link
Member

Choose a reason for hiding this comment

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

I'd love to remove this config at some point and just use whatever default Prettier uses.

Copy link
Member Author

Choose a reason for hiding this comment

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

I just checked and removing this config would replace all single quotes with doubles. If you don't mind, I can do this in this PR

Copy link
Member

Choose a reason for hiding this comment

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

Let's do it in a separate PR. I think we want to upgrade to 3.x as well.

Comment on lines 5 to 9
"main": "lib/commonjs/index",
"module": "lib/module/index",
"types": "lib/typescript/index.d.ts",
"react-native": "src/index",
"source": "src/index",
Copy link
Member

Choose a reason for hiding this comment

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

We should also include an exports map. Metro started supporting it recently.

Also, why are we missing the extensions? Platform forking is not applied to entry point files regardless.

Copy link
Member Author

Choose a reason for hiding this comment

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

I copied this from bob setup, so there was no file ext.
TIL about exports 😄 replaced it now

Copy link
Member

Choose a reason for hiding this comment

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

Since this is only used as base, can we move it into a .config folder to hide the clutter in root?

Copy link
Member Author

Choose a reason for hiding this comment

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

I would opt out of doing that, as this might decrease DX. IDE like Webstorm picks those config files and enables support based on their existence

Copy link
Member

Choose a reason for hiding this comment

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

Webstorm doesn't pick the nearest config?

Copy link
Member Author

Choose a reason for hiding this comment

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

You're right! I had problem with monorepo and diff eslint on Webstorm in other project, but the quick check proved it picks the nearest config!

"eslint-plugin-wdio": "^8.8.7",
"expo": "^48.0.0",
"lodash": "^4.17.21",
"prettier": "^2.5.1",
"prettier": "2.4.1",
Copy link
Member

Choose a reason for hiding this comment

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

Why did we roll back to an older version?

Copy link
Member Author

Choose a reason for hiding this comment

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

I meant to unify the versions from core and this package. Installed 2.5.1 instead.

@krizzu
Copy link
Member Author

krizzu commented Aug 31, 2023

@tido64 thanks for review 🙏 I'll do another PR with Prettier upgrade and moving of config files

@krizzu krizzu merged commit 9f694f0 into main Aug 31, 2023
@krizzu krizzu deleted the feat/core branch August 31, 2023 10:18
@AsyncStorageBot
Copy link
Collaborator

🎉 This PR is included in version 1.19.4 🎉

The release is available on:

Your semantic-release bot 📦🚀

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants