Skip to content

i cannot see highlight tags on screen when i loaded annotators (json format) #723

@cuiwang

Description

@cuiwang

hello,I was used annotator v2.0.3 in a base vue2 application, but a bug(maybe) confused me.
i got a RangeError{type: "start", message: "Couldn't find start node: /div[1]/div[2]/span[222]", parent: null}.

first:
i defined MyLocalStorage (mostly like node_modules/annotator/src/storage.js:function:: debug() )

partly code:
// tempArr : {quote: "建筑技术", ranges: Array(1), custom: "custom", text: "123", tags: Array(0), …}
query: function (queryObj) {
			return {results:tempArr};
		}

second:

this.annotatorApp.start().then(() => {
        this.annotatorApp.annotations.load()
      })

finally:

i got this in highlighter.js , function reanchorRange :

RangeError {type: "start", message: "Couldn't find start node: /div[1]/div[2]/span[222]", parent: null}

so, how can i correct restore localstorage annotators on screen?

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions