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

Release as a package and monorepo structure #87

Merged
merged 29 commits into from
Sep 1, 2023

Conversation

eyalcohen4
Copy link
Contributor

@eyalcohen4 eyalcohen4 commented Jul 9, 2023

Overview

This PR allow for publishing novel as a package.
We have used turborepo to enable it, and moved the repository into a monorepo structure.
In order to re-use the tailwind and ts configuration, we've created 2 packages called tailwind-config and ts-config that are shared between the novel package and the app.

The novel package is built using tsup.

New commands

Since we moved to a monorepo structure, dev and build commands should be run in the root folder.
To run the project now, you can run $ pnpm run dev in the root folder, and to build it for release you should call $ pnpm run build in the root folder as well.

New Repo Structure

- packages
  - novel
  - tailwind-config
  - ts-config
- apps
  - web

Todo List

  • Added turborepo
  • Split to 4 packages: web app, shared tailwind-config, shared ts-config, and the novel editor
  • Update the novel package to expose an API via props
  • Prepare for npm release
  • Update to latest version on main branch

@vercel
Copy link

vercel bot commented Jul 9, 2023

@eyalcohen4 is attempting to deploy a commit to the Elegance Team on Vercel.

A member of the Team first needs to authorize it.

@socket-security
Copy link

socket-security bot commented Jul 9, 2023

New and removed dependencies detected. Learn more about Socket for GitHub ↗︎

Packages Version New capabilities Transitives Size Publisher
turbo 1.9.3 network, filesystem, environment +0 44.2 kB turbobot
next 13.4.8-canary.14 None +4 56 MB vercel-release-bot
tsup 7.1.0 eval, network, filesystem, shell, environment +2 651 kB egoist
tailwindcss 3.3.2 None +3 8.64 MB adamwathan

🚮 Removed packages: @playwright/test@1.36.2, @replayio/playwright@1.0.10, novel@0.1.0

@socket-security
Copy link

socket-security bot commented Jul 9, 2023

👍 Dependency issues cleared. Learn more about Socket for GitHub ↗︎

This PR previously contained dependency changes with security issues that have been resolved, removed, or ignored.

@eyalcohen4
Copy link
Contributor Author

eyalcohen4 commented Jul 20, 2023

Sorry for the delay! Had a company offsite so couldn't work on it. expecting to have the time to ship it next week.
And if anybody want's to help moving this forward feel free!

@eyalcohen4 eyalcohen4 changed the title Release as a package and monorepo Structure Release as a package and monorepo structure Jul 29, 2023
@eyalcohen4 eyalcohen4 marked this pull request as ready for review July 29, 2023 14:57
@eyalcohen4
Copy link
Contributor Author

@steven-tey This is ready for review! The novel package is also ready to be published, feel free to publish where ever you want.

We can iterate and improve in a new PR on:

  • Extensions as a prop
  • Release CI/CD

I know lot of people need this PR to be done already (including me) so we can first release and then improved.
lmk what you think and feel free to comment on anything that doesn't makes sense.

@junoriosity
Copy link

@eyalcohen4 @steven-tey Is there some update on that matter?

It would be terrific to get to make a package out of this. 🙂

@eyalcohen4
Copy link
Contributor Author

ready for review :)

@vercel
Copy link

vercel bot commented Aug 9, 2023

The latest updates on your projects. Learn more about Vercel for Git ↗︎

Name Status Preview Comments Updated (UTC)
novel ✅ Ready (Inspect) Visit Preview 💬 Add feedback Sep 1, 2023 4:32am

@steven-tey
Copy link
Owner

steven-tey commented Aug 9, 2023

Apologies for the delay here!

I'm looping in @jaril to help refactor some of the Playwright config from #93 🙏

We should be able to merge this soon – super excited :aaaaaa:

@junoriosity
Copy link

@eyalcohen4 @steven-tey Many thanks for your effort, this is super cool.

I am so much looking forward to it. 🙂

@junoriosity
Copy link

@eyalcohen4 @steven-tey @jaril Are there some news in getting novel released as package?

If so, it would be terrific to have a small manual that covers things like

  • how to embed it into a frontend
  • how to customize it, for instance,
    • changing the design of some parts of novel,
    • adding new functions to the notion-like menu
  • adding collaboration support via y-js via Prosemirror (https://github.com/yjs/y-prosemirror) or something.

Would that be possible? 🙂

@eyalcohen4
Copy link
Contributor Author

Would love to get it out as well! @junoriosity
@jaril - Anything I could help here to adapt the playwright tests?

@vercel
Copy link

vercel bot commented Aug 31, 2023

Deployment failed with the following error:

The provided GitHub repository does not contain the requested branch or commit reference. Please ensure the repository is not empty.

@steven-tey
Copy link
Owner

Sneak peek: https://www.npmjs.com/package/novel 👀

Finally got that sweet novel package name haha

CleanShot 2023-08-31 at 17 15 30

@steven-tey
Copy link
Owner

Would love to get it out as well! @junoriosity @jaril - Anything I could help here to adapt the playwright tests?

We're ditching the playwright tests for now btw, @jaril will add it back in another PR for the monorepo! 🙏

@steven-tey
Copy link
Owner

Merging now! Here goes nothing 🙈

@steven-tey steven-tey merged commit 5f2f944 into steven-tey:main Sep 1, 2023
1 of 2 checks passed
@junoriosity
Copy link

@steven-tey I have seen quite some activity here. :)

Is the package published now or is there still something left to be done?

@steven-tey
Copy link
Owner

@junoriosity it's published: https://www.npmjs.com/package/novel

Launching it on Twitter/LinkedIn soon! :)

@elie222
Copy link

elie222 commented Sep 3, 2023

Nice! Love this made it in

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

Successfully merging this pull request may close these issues.

None yet

4 participants