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

Project structure improvements #185

Merged
merged 22 commits into from
Dec 22, 2021
Merged

Project structure improvements #185

merged 22 commits into from
Dec 22, 2021

Conversation

sekaiking
Copy link
Contributor

@sekaiking sekaiking commented Dec 16, 2021

Summary

  • I upgraded Yarn to version 3 because it offers some helpful features such as workspace ranges and release workflow which we can use to automate the publishing of packages

  • Now using yalc for developement is unnecessary, because the frontend is resolving the local packages automatically from the workspace.

  • Upgraded to NextJs 12 because it's fast and cool. And it allows us to have hot reloading without needing next-transpile-modules thanks to externalDir

  • Also, I fixed all eslint errors which were filling the console log and causing vscode to show errors

  • And, optimized images from the homepage to make them load a bit faster

  • And to make it easy for developers, there is a new set of commands that we can call anywhere from the project folder. (Also added them to README)

yarn dev:components
yarn dev:frontend  // hot reloading of the local packages is enabled by default
yarn build:components
yarn build:storybook
yarn build:hooks
yarn build:frontend
yarn test:contracts
yarn test:hooks

This PR will make it helpful to move on with #120 and #114

Note

This update require some changes to Vercel settings, as following:
image

@vercel
Copy link

vercel bot commented Dec 16, 2021

This pull request is being automatically deployed with Vercel (learn more).
To see the status of your deployments, click below or on the icon next to each commit.

frontend – ./examples/frontend

🔍 Inspect: https://vercel.com/curaos/frontend/YGPjotTXC9iPVTb1uhNCdRPG2f1a
✅ Preview: https://frontend-git-cleanup-curaos.vercel.app

frontend-dev – ./

🔍 Inspect: https://vercel.com/testtete/frontend-dev/3VA9HyaR6UawE9SmeZZmLjSVDAbp
✅ Preview: https://frontend-dev-git-cleanup-testtete.vercel.app

@sekaiking sekaiking self-assigned this Dec 18, 2021
@sekaiking
Copy link
Contributor Author

Hey @AshenI99, can you test this changes if they work fine for you?

Just checkout clean_up branch and run the install command, then test each command to make sure it's working as it should

Copy link
Collaborator

@AshenI99 AshenI99 left a comment

Choose a reason for hiding this comment

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

Here is the review status.

  • yarn dev:frontend : working perfectly. Changes made to the hooks and components are appearing instantly without any issue.

  • yarn dev:components : working perfectly. Changes made to the hooks and components are appearing instantly without any issue.

  • yarn build:components : working perfectly. Building the components/dist folder without any issue

  • yarn build:hooks : working perfectly. Building the hooks/dist folder without any issue

  • yarn build:frontend : getting the below issue.

Screenshot 2021-12-20 at 15 12 12

Everything working perfectly except yarn build:frontend.

Great Job!💯 This will make the coding process more easier. 🙂👌

@bestatigen bestatigen changed the title Clean up Project structure improvements Dec 21, 2021
Copy link
Collaborator

@bestatigen bestatigen left a comment

Choose a reason for hiding this comment

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

Looks solid! A lot of minor and major version changes so let's make sure nothing breaks, which doesn't seem to at first look. I have a few doubts that I commented on, other than that thanks for taking this on and carrying it over the finish line!

examples/frontend/pages/devs/index.tsx Show resolved Hide resolved
examples/frontend/package.json Outdated Show resolved Hide resolved
examples/frontend/package.json Outdated Show resolved Hide resolved
examples/frontend/pages/_app.tsx Show resolved Hide resolved
@sekaiking
Copy link
Contributor Author

Closed #116 and #149 because they are nonrelevant cause of this PR

@sekaiking
Copy link
Contributor Author

Had to install @type/bn.js because of an error caused by the latest near-api-js version
log here: https://vercel.com/testtete/frontend-dev/8Q75NRm1WttWFEwZv5G2k8fK6dJQ

@bestatigen bestatigen merged commit e48e339 into master Dec 22, 2021
@sekaiking sekaiking deleted the clean_up branch December 23, 2021 13:20
@sekaiking sekaiking mentioned this pull request Dec 29, 2021
8 tasks
@github-actions
Copy link

🎉 This PR is included in version @cura/hooks-v1.0.0 🎉

The release is available on:

Your semantic-release bot 📦🚀

@github-actions
Copy link

🎉 This PR is included in version @cura/components-v1.0.0 🎉

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
No open projects
Status: Done
Development

Successfully merging this pull request may close these issues.

3 participants