From 682c542c91b80251560c40ca68d7c8f556e91f15 Mon Sep 17 00:00:00 2001 From: Robert Knight Date: Tue, 18 Jul 2023 12:49:48 +0100 Subject: [PATCH] Document `contentReady` configuration setting --- docs/publishers/config.rst | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/docs/publishers/config.rst b/docs/publishers/config.rst index 8455bc4abd3..1563b333595 100644 --- a/docs/publishers/config.rst +++ b/docs/publishers/config.rst @@ -352,6 +352,14 @@ loads. of that text when it is being viewed as well as the font-family of the editor as the annotation is being written. +.. option:: contentReady + + ``Promise``. A promise that signals to Hypothesis when the document's content + is ready. In web applications where the content loads asynchronously, this + allows Hypothesis to be loaded concurrently with the content, while making + sure that Hypothesis waits for the content to be ready before attempting to + locate annotated content in the document. + .. option:: onLayoutChange ``function``. This function will be a registered callback to be invoked when the sidebar