Annotate EPUB files using Epub.js and xyAnnotations.

Usage no npm install needed!

<script type="module">
  import xyfirAnnotateEpubjs from 'https://cdn.skypack.dev/@xyfir/annotate-epubjs';


Annotate EPUB books using Epub.js v0.3 and xyAnnotations.

Usage / Examples

Check the tests folder (and test.jsx specifically) for a detailed, up-to-date, working example of this package being used.

While the module contains many methods that you can use for more complex integrations (see the source for more info), the only method you really need is AnnotateEPUBJS.insertAnnotations(book, annotationSet), where book is the Epub.js Book instance and annotationSet is an annotation set object as received from GET annotations.xyfir.com/api/sets/:set/download.