Merge pull request #528 from jamesgpearce/patch-1

Add missing getting-started steps
This commit is contained in:
Kevin Jahns 2023-05-05 12:21:56 +02:00 committed by GitHub
commit 5db1eed181
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -169,6 +169,9 @@ PORT=1234 node ./node_modules/y-websocket/bin/server.js
### Example: Observe types
```js
import * as Y from 'yjs';
const doc = new Y.Doc();
const yarray = doc.getArray('my-array')
yarray.observe(event => {
console.log('yarray was modified')