src/model/fragment.js
// replaces, should not be text nodes.
replaces, should not be text nodes.
replaces should not be text nodes .
replace(offset, node) {
    if (node.isText) ModelError.raise("Argument to replace should be a non-text node")
    let copy = this.content.slice()
    copy[offset] = node
    return new FlatFragment(copy)
  }
replace ( offset , node ) { if ( node . isText ) ModelError . raise ( "Argument to replace should be a non-text node" ) let copy = this . content . slice ( ) copy [ offset ] = node return new FlatFragment ( copy ) }
replaces, should not be text nodes.
replaces should not be text nodes .