Index: doc/API_web.md ================================================================== --- doc/API_web.md +++ doc/API_web.md @@ -42,20 +42,28 @@ if (typeof(oGrammalecteAPI) === "object" && oGrammalecteAPI !== null) { ... } +When the Grammalecte API is ready, it sends an event called `GrammalecteLoaded` on the `document` node. + +You can detect it with: + + document.addEventListener("GrammalecteLoaded", function (event) { + ... + }); + ### Version of the Grammalecte API oGrammalecteAPI.sVersion ### Disabling the Grammalecte button (the spinning pearl) By default, Grammalecte inserts a button (a spinning pearl) on each textarea node and editable node (unless the user disabled it). -You can tell Grammalete not to create these buttons on your text areas with the property: `data-grammalecte_button="false"`. +You can tell Grammalecte not to create these buttons on your text areas with the property: `data-grammalecte_button="false"`. ### Open the Grammalecte panel for a node If you have disabled the spinning button, you can launch the Grammalecte panel with your custom button.