mirror of
https://github.com/ueberdosis/tiptap.git
synced 2024-12-26 02:37:49 +08:00
f387ad3dd4
* chore:(core): migrate to tsup * chore: migrate blockquote and bold to tsup * chore: migrated bubble-menu and bullet-list to tsup * chore: migrated more packages to tsup * chore: migrate code and character extensions to tsup * chore: update package.json to simplify build for all packages * chore: move all packages to tsup as a build process * chore: change ci build task * feat(pm): add prosemirror meta package * rfix: resolve issues with build paths & export mappings * docs: update documentation to include notes for @tiptap/pm * chore(pm): update tsconfig * chore(packages): update packages * fix(pm): add package export infos & fix dependencies * chore(general): start moving to pm package as deps * chore: move to tiptap pm package internally * fix(demos): fix demos working with new pm package * fix(tables): fix tables package * fix(tables): fix tables package * chore(demos): pinned typescript version * chore: remove unnecessary tsconfig * chore: fix netlify build * fix(demos): fix package resolving for pm packages * fix(tests): fix package resolving for pm packages * fix(tests): fix package resolving for pm packages * chore(tests): fix tests not running correctly after pm package * chore(pm): add files to files array * chore: update build workflow * chore(tests): increase timeout time back to 12s * chore(docs): update docs * chore(docs): update installation guides & pm information to docs * chore(docs): add link to prosemirror docs * fix(vue-3): add missing build step * chore(docs): comment out cdn link * chore(docs): remove semicolons from docs * chore(docs): remove unnecessary installation note * chore(docs): remove unnecessary installation note
28 lines
2.3 KiB
Markdown
28 lines
2.3 KiB
Markdown
# Introduction
|
||
Tiptap is a friendly wrapper around [ProseMirror](https://ProseMirror.net). Although Tiptap tries to hide most of the complexity of ProseMirror, it’s built on top of its APIs and we recommend you to read through the [ProseMirror Guide](https://ProseMirror.net/docs/guide/) for advanced usage.
|
||
|
||
### Structure
|
||
ProseMirror works with a strict [Schema](/api/schema), which defines the allowed structure of a document. A document is a tree of headings, paragraphs and others elements, so called nodes. Marks can be attached to a node, e. g. to emphasize part of it. [Commands](/api/commands) change that document programmatically.
|
||
|
||
### Content
|
||
The document is stored in a state. All changes are applied as transactions to the state. The state has details about the current content, cursor position and selection. You can hook into a few different [events](/api/events), for example to alter transactions before they get applied.
|
||
|
||
### Extensions
|
||
Extensions add [nodes](/api/nodes), [marks](/api/marks) and/or [functionalities](/api/extensions) to the editor. A lot of those extensions bound their commands to common [keyboard shortcuts](/api/keyboard-shortcuts).
|
||
|
||
## Vocabulary
|
||
ProseMirror has its own vocabulary and you’ll stumble upon all those words now and then. Here is a short overview of the most common words we use in the documentation.
|
||
|
||
| Word | Description |
|
||
| ----------- | ------------------------------------------------------------------------ |
|
||
| Schema | Configures the structure your content can have. |
|
||
| Document | The actual content in your editor. |
|
||
| State | Everything to describe the current content and selection of your editor. |
|
||
| Transaction | A change to the state (updated selection, content, …) |
|
||
| Extension | Registers new functionality. |
|
||
| Node | A type of content, for example a heading or a paragraph. |
|
||
| Mark | Can be applied to nodes, for example for inline formatting. |
|
||
| Command | Execute an action inside the editor, that somehow changes the state. |
|
||
| Decoration | Styling on top of the document, for example to highlight mistakes. |
|
||
|