indexOf(charOrId, includeDeleted) {
    invariant(charOrId, 'From char must be defined.')
    let id = _.has(charOrId, 'id') ? charOrId.id : charOrId
    for (let i = 0; i < this.data.len(); i++) {
      if (this.data.matches(i, id, includeDeleted)) return i
    }
    return -1
  }
Returns the index of a given char or ID. Index 0 is always the BASE_CHAR. If the char is not
found, returns -1.
@param {Char|number} charOrId
@param {boolean} [includeDeleted=true] Whether to include deletec chars in the match.
@returns number