@forevka/wordcanvas 0.3.0 → 0.3.2

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.
Files changed (2) hide show
  1. package/README.md +29 -0
  2. package/package.json +18 -18
package/README.md CHANGED
@@ -10,6 +10,35 @@ The published bundle is **self-contained**: it has **zero runtime dependencies**
10
10
  code-split). You can drop it onto a page with a plain `<script type="module">` or
11
11
  import it from any bundler.
12
12
 
13
+ ## How it compares
14
+
15
+ If you have shopped for an embeddable Word editor, you have met Syncfusion
16
+ Document Editor, OnlyOffice, and DevExpress Rich Text Editor. They are mature
17
+ and cover more of the Word long tail than this package does. They also ask for a
18
+ commercial per-seat license, and two of the three want a server running before
19
+ the editor renders a page.
20
+
21
+ WordCanvas takes the other trade. It ships under MIT, paints to a `<canvas>`
22
+ the way Google Docs has since 2021, and runs fully in the browser with zero
23
+ runtime dependencies. You only stand up a backend if you want live
24
+ collaboration; reading, editing, and DOCX/PDF export all work offline.
25
+
26
+ | | WordCanvas | Syncfusion Document Editor | OnlyOffice | DevExpress Rich Text |
27
+ |---|---|---|---|---|
28
+ | License | MIT | Commercial seat | AGPL or commercial | Commercial seat |
29
+ | Rendering | Canvas | DOM | Canvas (in an iframe) | DOM |
30
+ | Server required to render | No | For some file conversions | Yes (Document Server) | Yes (.NET backend) |
31
+ | Runtime dependencies | Zero | Several | Bundled suite | .NET stack |
32
+ | DOCX import + export | In-browser | Yes | Yes | Yes |
33
+ | PDF export | Page-accurate, in-browser | Yes | Yes | Yes |
34
+ | Live collaboration | Built in (opt-in backend) | Add-on | Built in | Add-on |
35
+ | Primary target | Any JS app | Angular/React/Vue | Iframe / full suite | Blazor / .NET |
36
+
37
+ Where the commercial editors win today: RTL and complex-script editing, bundled
38
+ CJK fonts, charts and equations, and an enterprise support contract. The full
39
+ breakdown, including what each one does better, lives in
40
+ [Best embeddable JS Word editors](https://forevka.dev/articles/best-embeddable-js-word-editors/).
41
+
13
42
  ## Install
14
43
 
15
44
  ```sh
package/package.json CHANGED
@@ -1,8 +1,8 @@
1
1
  {
2
2
  "name": "@forevka/wordcanvas",
3
- "version": "0.3.0",
3
+ "version": "0.3.2",
4
4
  "type": "module",
5
- "description": "Embeddable canvas-rendered, Word-compatible document editor with live collaboration and DOCX/PDF import & export. Self-contained, zero runtime dependencies.",
5
+ "description": "Open-source embeddable Word-style document editor: canvas-rendered, with live collaboration and DOCX/PDF import & export. A lightweight alternative to Syncfusion, OnlyOffice, and DevExpress document editors. Self-contained, zero runtime dependencies.",
6
6
  "license": "MIT",
7
7
  "author": "Bohdan Lushchyk",
8
8
  "homepage": "https://github.com/Forevka/canvas-word#readme",
@@ -17,38 +17,38 @@
17
17
  "keywords": [
18
18
  "word",
19
19
  "editor",
20
+ "word-editor",
21
+ "word-processor",
22
+ "document-editor",
20
23
  "docx",
24
+ "docx-editor",
21
25
  "pdf",
22
26
  "canvas",
23
27
  "wysiwyg",
24
28
  "rich-text",
25
29
  "document",
26
- "collaboration"
30
+ "collaboration",
31
+ "embeddable",
32
+ "syncfusion-alternative",
33
+ "onlyoffice-alternative",
34
+ "devexpress-alternative",
35
+ "contenteditable-alternative"
27
36
  ],
28
37
  "module": "./dist-lib/wordcanvas.js",
29
38
  "types": "./types/wordcanvas.d.ts",
39
+ "//exports": "Only the surface that is actually shipped (files: dist-lib + types). The frontend's import/export pipelines are consumed in-workspace by the backend via its tsconfig paths + vitest aliases, NOT through this map, so they are intentionally not published. Note: npm's publishConfig does NOT override `exports`, so this committed map is what ships — keep it pointing at dist, not src.",
30
40
  "exports": {
31
41
  ".": {
32
42
  "types": "./types/wordcanvas.d.ts",
33
43
  "import": "./dist-lib/wordcanvas.js"
34
44
  },
35
- "./builder": "./src/builder/index.ts",
36
- "./import": "./src/import/docx/pipeline.ts",
37
- "./export": "./src/export/pipeline.ts",
38
- "./export/measure": "./src/export/shared/measureHost.ts"
45
+ "./builder": {
46
+ "types": "./types/builder.d.ts",
47
+ "import": "./dist-lib/builder.js"
48
+ }
39
49
  },
40
50
  "publishConfig": {
41
- "access": "public",
42
- "exports": {
43
- ".": {
44
- "types": "./types/wordcanvas.d.ts",
45
- "import": "./dist-lib/wordcanvas.js"
46
- },
47
- "./builder": {
48
- "types": "./types/builder.d.ts",
49
- "import": "./dist-lib/builder.js"
50
- }
51
- }
51
+ "access": "public"
52
52
  },
53
53
  "files": ["dist-lib", "types"],
54
54
  "scripts": {