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

feat(table): make all table packages be in one package, add a new TableKit extension to configure them #5469

Merged
merged 3 commits into from
Jan 6, 2025

Conversation

nperez0111
Copy link
Contributor

@nperez0111 nperez0111 commented Aug 11, 2024

Changes Overview

This represents a departure from our previous packaging approach. Instead of having a package for every single possible functionality that goes into the editor, we can reduce the number of packages by grouping them by functionality.
We believe that Tiptap's strength comes from it's modularity and this is no exception, each extension can still be installed separately, just under a new package namespace. But, it will definitely clean up your package.json to not have each component of a table as a package.

Implementation Approach

Following the approach set forth by @tiptap/starter-kit this groups and installs the extensions for table all in a single package and import, greatly reducing duplication and reducing error of forgetting to install a package.

Once we decide that we like this approach, I can move forward with grouping:

  • text formatting: (bold, code, highlight, italic, strike, subscript, superscript, underline)
  • lists: (bullet list, ordered list, list item, list item keymap, task list, task item)
  • text styles: (color, font-family, text-align, text-style)

And, any other groupings that seem obvious to make.

Testing Done

Verification Steps

Additional Notes

Checklist

  • I have created a changeset for this PR if necessary.
  • My changes do not break the library.
  • I have added tests where applicable.
  • I have followed the project guidelines.
  • I have fixed any lint issues.

Related Issues

Copy link

changeset-bot bot commented Aug 11, 2024

🦋 Changeset detected

Latest commit: 6c0f8e8

The changes in this PR will be included in the next version bump.

This PR includes changesets to release 55 packages
Name Type
@tiptap/extension-table-header Minor
@tiptap/extension-table-cell Minor
@tiptap/extension-table-row Minor
@tiptap/extension-table Minor
@tiptap/core Minor
@tiptap/extension-blockquote Minor
@tiptap/extension-bold Minor
@tiptap/extension-bubble-menu Minor
@tiptap/extension-bullet-list Minor
@tiptap/extension-character-count Minor
@tiptap/extension-code-block-lowlight Minor
@tiptap/extension-code-block Minor
@tiptap/extension-code Minor
@tiptap/extension-collaboration-cursor Minor
@tiptap/extension-collaboration Minor
@tiptap/extension-color Minor
@tiptap/extension-document Minor
@tiptap/extension-dropcursor Minor
@tiptap/extension-floating-menu Minor
@tiptap/extension-focus Minor
@tiptap/extension-font-family Minor
@tiptap/extension-font-size Minor
@tiptap/extension-gapcursor Minor
@tiptap/extension-hard-break Minor
@tiptap/extension-heading Minor
@tiptap/extension-highlight Minor
@tiptap/extension-history Minor
@tiptap/extension-horizontal-rule Minor
@tiptap/extension-image Minor
@tiptap/extension-italic Minor
@tiptap/extension-link Minor
@tiptap/extension-list-item Minor
@tiptap/extension-list-keymap Minor
@tiptap/extension-mention Minor
@tiptap/extension-ordered-list Minor
@tiptap/extension-paragraph Minor
@tiptap/extension-placeholder Minor
@tiptap/extension-strike Minor
@tiptap/extension-subscript Minor
@tiptap/extension-superscript Minor
@tiptap/extension-task-item Minor
@tiptap/extension-task-list Minor
@tiptap/extension-text-align Minor
@tiptap/extension-text-style Minor
@tiptap/extension-text Minor
@tiptap/extension-typography Minor
@tiptap/extension-underline Minor
@tiptap/extension-youtube Minor
@tiptap/html Minor
@tiptap/pm Minor
@tiptap/react Minor
@tiptap/starter-kit Minor
@tiptap/suggestion Minor
@tiptap/vue-2 Minor
@tiptap/vue-3 Minor

Not sure what this means? Click here to learn what changesets are.

Click here if you're a maintainer who wants to add another changeset to this PR

Copy link

netlify bot commented Aug 11, 2024

Deploy Preview for tiptap-embed ready!

Name Link
🔨 Latest commit 6c0f8e8
🔍 Latest deploy log https://app.netlify.com/sites/tiptap-embed/deploys/6777a1624a8c1f00080a76b8
😎 Deploy Preview https://deploy-preview-5469--tiptap-embed.netlify.app
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.

To edit notification comments on pull requests, go to your Netlify site configuration.

@nperez0111 nperez0111 marked this pull request as draft August 11, 2024 17:20
@nperez0111
Copy link
Contributor Author

I've had a change of heart since implementing this, it may be worthwhile to keep the extraneous packages for at least one major version longer just to not break people on them changing their version. They should remove the packages but let's have a nicer upgrade experience. Also allows people to beta test

Copy link

pkg-pr-new bot commented Dec 30, 2024

Open in Stackblitz

@tiptap/core

npm i https://pkg.pr.new/@tiptap/core@5469

@tiptap/extension-blockquote

npm i https://pkg.pr.new/@tiptap/extension-blockquote@5469

@tiptap/extension-bubble-menu

npm i https://pkg.pr.new/@tiptap/extension-bubble-menu@5469

@tiptap/extension-bold

npm i https://pkg.pr.new/@tiptap/extension-bold@5469

@tiptap/extension-bullet-list

npm i https://pkg.pr.new/@tiptap/extension-bullet-list@5469

@tiptap/extension-character-count

npm i https://pkg.pr.new/@tiptap/extension-character-count@5469

@tiptap/extension-code

npm i https://pkg.pr.new/@tiptap/extension-code@5469

@tiptap/extension-code-block

npm i https://pkg.pr.new/@tiptap/extension-code-block@5469

@tiptap/extension-code-block-lowlight

npm i https://pkg.pr.new/@tiptap/extension-code-block-lowlight@5469

@tiptap/extension-collaboration

npm i https://pkg.pr.new/@tiptap/extension-collaboration@5469

@tiptap/extension-collaboration-cursor

npm i https://pkg.pr.new/@tiptap/extension-collaboration-cursor@5469

@tiptap/extension-color

npm i https://pkg.pr.new/@tiptap/extension-color@5469

@tiptap/extension-document

npm i https://pkg.pr.new/@tiptap/extension-document@5469

@tiptap/extension-dropcursor

npm i https://pkg.pr.new/@tiptap/extension-dropcursor@5469

@tiptap/extension-focus

npm i https://pkg.pr.new/@tiptap/extension-focus@5469

@tiptap/extension-floating-menu

npm i https://pkg.pr.new/@tiptap/extension-floating-menu@5469

@tiptap/extension-font-family

npm i https://pkg.pr.new/@tiptap/extension-font-family@5469

@tiptap/extension-font-size

npm i https://pkg.pr.new/@tiptap/extension-font-size@5469

@tiptap/extension-gapcursor

npm i https://pkg.pr.new/@tiptap/extension-gapcursor@5469

@tiptap/extension-hard-break

npm i https://pkg.pr.new/@tiptap/extension-hard-break@5469

@tiptap/extension-heading

npm i https://pkg.pr.new/@tiptap/extension-heading@5469

@tiptap/extension-highlight

npm i https://pkg.pr.new/@tiptap/extension-highlight@5469

@tiptap/extension-history

npm i https://pkg.pr.new/@tiptap/extension-history@5469

@tiptap/extension-horizontal-rule

npm i https://pkg.pr.new/@tiptap/extension-horizontal-rule@5469

@tiptap/extension-image

npm i https://pkg.pr.new/@tiptap/extension-image@5469

@tiptap/extension-italic

npm i https://pkg.pr.new/@tiptap/extension-italic@5469

@tiptap/extension-link

npm i https://pkg.pr.new/@tiptap/extension-link@5469

@tiptap/extension-list-item

npm i https://pkg.pr.new/@tiptap/extension-list-item@5469

@tiptap/extension-list-keymap

npm i https://pkg.pr.new/@tiptap/extension-list-keymap@5469

@tiptap/extension-ordered-list

npm i https://pkg.pr.new/@tiptap/extension-ordered-list@5469

@tiptap/extension-paragraph

npm i https://pkg.pr.new/@tiptap/extension-paragraph@5469

@tiptap/extension-placeholder

npm i https://pkg.pr.new/@tiptap/extension-placeholder@5469

@tiptap/extension-mention

npm i https://pkg.pr.new/@tiptap/extension-mention@5469

@tiptap/extension-strike

npm i https://pkg.pr.new/@tiptap/extension-strike@5469

@tiptap/extension-subscript

npm i https://pkg.pr.new/@tiptap/extension-subscript@5469

@tiptap/extension-superscript

npm i https://pkg.pr.new/@tiptap/extension-superscript@5469

@tiptap/extension-table

npm i https://pkg.pr.new/@tiptap/extension-table@5469

@tiptap/extension-table-cell

npm i https://pkg.pr.new/@tiptap/extension-table-cell@5469

@tiptap/extension-table-header

npm i https://pkg.pr.new/@tiptap/extension-table-header@5469

@tiptap/extension-table-row

npm i https://pkg.pr.new/@tiptap/extension-table-row@5469

@tiptap/extension-task-item

npm i https://pkg.pr.new/@tiptap/extension-task-item@5469

@tiptap/extension-task-list

npm i https://pkg.pr.new/@tiptap/extension-task-list@5469

@tiptap/extension-text

npm i https://pkg.pr.new/@tiptap/extension-text@5469

@tiptap/extension-text-align

npm i https://pkg.pr.new/@tiptap/extension-text-align@5469

@tiptap/extension-text-style

npm i https://pkg.pr.new/@tiptap/extension-text-style@5469

@tiptap/extension-typography

npm i https://pkg.pr.new/@tiptap/extension-typography@5469

@tiptap/extension-underline

npm i https://pkg.pr.new/@tiptap/extension-underline@5469

@tiptap/extension-youtube

npm i https://pkg.pr.new/@tiptap/extension-youtube@5469

@tiptap/html

npm i https://pkg.pr.new/@tiptap/html@5469

@tiptap/pm

npm i https://pkg.pr.new/@tiptap/pm@5469

@tiptap/react

npm i https://pkg.pr.new/@tiptap/react@5469

@tiptap/starter-kit

npm i https://pkg.pr.new/@tiptap/starter-kit@5469

@tiptap/suggestion

npm i https://pkg.pr.new/@tiptap/suggestion@5469

@tiptap/vue-2

npm i https://pkg.pr.new/@tiptap/vue-2@5469

@tiptap/vue-3

npm i https://pkg.pr.new/@tiptap/vue-3@5469

commit: 6c0f8e8

@nperez0111 nperez0111 marked this pull request as ready for review December 30, 2024 09:32
@nperez0111
Copy link
Contributor Author

@bdbch & @svenadlung this is ready for review now.

I decided that this PR should only try to do the grouping for tables. It also keeps compatibility with the existing @tiptap/extension-table-cell package by doing a re-export of what @tiptap/extension-table has.

Copy link
Member

@bdbch bdbch left a comment

Choose a reason for hiding this comment

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

LGTM

Copy link
Member

@bdbch bdbch left a comment

Choose a reason for hiding this comment

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

LGTM

@bdbch bdbch merged commit 131c7d0 into next Jan 6, 2025
15 checks passed
@bdbch bdbch deleted the kits branch January 6, 2025 06:02
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
No open projects
Status: Triage open
Development

Successfully merging this pull request may close these issues.

2 participants