Skip to content

Commit

Permalink
fix gc & proper options typings for Y.Doc, fixes #176
Browse files Browse the repository at this point in the history
  • Loading branch information
dmonad committed Dec 10, 2019
1 parent 7f0e25d commit 22917bc
Showing 1 changed file with 4 additions and 3 deletions.
7 changes: 4 additions & 3 deletions src/utils/Doc.js
Original file line number Diff line number Diff line change
Expand Up @@ -23,11 +23,12 @@ import * as map from 'lib0/map.js'
*/
export class Doc extends Observable {
/**
* @param {Object|undefined} conf configuration
* @param {Object} conf configuration
* @param {boolean} [conf.gc] Disable garbage collection (default: gc=true)
*/
constructor (conf = {}) {
constructor ({ gc = true } = {}) {
super()
this.gc = conf.gc || true
this.gc = gc
this.clientID = random.uint32()
/**
* @type {Map<string, AbstractType<YEvent>>}
Expand Down

0 comments on commit 22917bc

Please sign in to comment.