@kerebron/extension-automerge

0.0.12 • Public • Published

Kerebron extension for collaboration using automerge

Current state (WIP)

WARNING: this extension is currently broken.

Reasons:

I tried naive hacks but got stuck on tables support. The reason is a format of marks in document. Compare below 2 tables:

  1. Table with 2 rows, 1 cell each
<table>
  <tr>
    <th>1</th>
  </tr>
  <tr>
    <td>2</td>
  </tr>
</table>

Pseudocode of marks JSON structure:

[
  { "type": "th", "parents": ["table", "tr"] },
  { "text": "1" },
  { "type": "td", "parents": ["table", "tr"] },
  { "text": "2" }
]
  1. Table with 1 row, 2 cells
<table>
  <tr>
    <th>1</th>
    <td>2</td>
  </tr>
</table>

Pseudocode of marks JSON structure:

[
  { "type": "th", "parents": ["table", "tr"] },
  { "text": "1" },
  { "type": "td", "parents": ["table", "tr"] },
  { "text": "2" }
]

Currently, both tables produce same output which resulted in folding all tables into 1 row.

Description

Fork of https://github.com/automerge/automerge-prosemirror

Some internals of automerge-prosemirror are not exposed.

https://automerge.org/ https://automerge.org/blog/2023/11/06/automerge-repo/ https://automerge.org/docs/quickstart/

https://automerge.org/automerge/api-docs/js/ https://github.com/automerge/automerge-repo/tree/main/packages/automerge-repo/src

Readme

Keywords

none

Package Sidebar

Install

npm i @kerebron/extension-automerge

Weekly Downloads

8

Version

0.0.12

License

MIT

Unpacked Size

216 kB

Total Files

88

Last publish

Collaborators

  • ggodlewski
  • horner