@lyfie/luthor-headless 2.0.1 → 2.1.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +58 -0
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -41,6 +41,24 @@ function MyEditor() {
|
|
|
41
41
|
|
|
42
42
|
## Quick Start
|
|
43
43
|
|
|
44
|
+
### Installation
|
|
45
|
+
|
|
46
|
+
Luthor-Headless is designed to be lightweight with Lexical packages as **peer dependencies**.
|
|
47
|
+
|
|
48
|
+
```bash
|
|
49
|
+
npm install @lyfie/luthor-headless
|
|
50
|
+
```
|
|
51
|
+
|
|
52
|
+
Install the required Lexical peer dependencies:
|
|
53
|
+
|
|
54
|
+
```bash
|
|
55
|
+
npm install lexical @lexical/react @lexical/html @lexical/markdown @lexical/list @lexical/rich-text @lexical/selection @lexical/utils @lexical/code @lexical/link @lexical/table
|
|
56
|
+
```
|
|
57
|
+
|
|
58
|
+
> **💡 Want a simpler setup?** Check out [@lyfie/luthor](../luthor/README.md) which bundles all Lexical dependencies for you.
|
|
59
|
+
|
|
60
|
+
### Basic Usage
|
|
61
|
+
|
|
44
62
|
```bash
|
|
45
63
|
npm install @lyfie/luthor-headless
|
|
46
64
|
```
|
|
@@ -106,6 +124,46 @@ export default function App() {
|
|
|
106
124
|
|
|
107
125
|
**That's it.** You now have a fully functional, type-safe rich text editor.
|
|
108
126
|
|
|
127
|
+
## Installation Options
|
|
128
|
+
|
|
129
|
+
### Option 1: Headless Package (This Package)
|
|
130
|
+
|
|
131
|
+
For maximum control and flexibility:
|
|
132
|
+
|
|
133
|
+
```bash
|
|
134
|
+
# Install headless package
|
|
135
|
+
npm install @lyfie/luthor-headless
|
|
136
|
+
|
|
137
|
+
# Manually install Lexical peer dependencies
|
|
138
|
+
npm install lexical @lexical/react @lexical/html @lexical/markdown @lexical/list @lexical/rich-text @lexical/selection @lexical/utils @lexical/code @lexical/link @lexical/table
|
|
139
|
+
```
|
|
140
|
+
|
|
141
|
+
**Use this when:**
|
|
142
|
+
- You want complete control over Lexical versions
|
|
143
|
+
- Building a custom editor UI from scratch
|
|
144
|
+
- Need minimum bundle size
|
|
145
|
+
- Want to manage dependencies yourself
|
|
146
|
+
|
|
147
|
+
### Option 2: Full Package (Recommended for Quick Start)
|
|
148
|
+
|
|
149
|
+
For a batteries-included experience:
|
|
150
|
+
|
|
151
|
+
```bash
|
|
152
|
+
# Install both packages
|
|
153
|
+
npm install @lyfie/luthor-headless
|
|
154
|
+
npm install @lyfie/luthor
|
|
155
|
+
|
|
156
|
+
# That's it! All Lexical dependencies included
|
|
157
|
+
```
|
|
158
|
+
|
|
159
|
+
**Use this when:**
|
|
160
|
+
- You want ready-to-use editor presets
|
|
161
|
+
- Don't want to manage Lexical dependencies
|
|
162
|
+
- Need a working editor quickly
|
|
163
|
+
- Want plug-and-play components
|
|
164
|
+
|
|
165
|
+
[📖 See @lyfie/luthor documentation](../luthor/README.md)
|
|
166
|
+
|
|
109
167
|
## Features
|
|
110
168
|
|
|
111
169
|
### 🎨 Built-in Extensions (25+)
|