From 69ac8e172278dd337ab61a8c0a53739db7d6a559 Mon Sep 17 00:00:00 2001 From: Luiza Pagliari Date: Mon, 20 Jun 2016 06:31:11 -0300 Subject: [PATCH] Include usage example for aceRegisterNonScrollableEditEvents --- doc/api/hooks_client-side.md | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/doc/api/hooks_client-side.md b/doc/api/hooks_client-side.md index 9d9cae250..9af035698 100644 --- a/doc/api/hooks_client-side.md +++ b/doc/api/hooks_client-side.md @@ -141,6 +141,13 @@ Things in context: None When aceEditEvent (documented above) finishes processing the event, it scrolls the viewport to make caret visible to the user, but if you don't want that behavior to happen you can use this hook to register which edit events should not scroll viewport. The return value of this hook should be a list of event names. +Example: +``` +exports.aceRegisterNonScrollableEditEvents = function(){ + return [ 'repaginate', 'updatePageCount' ]; +} +``` + ## aceRegisterBlockElements Called from: src/static/js/ace2_inner.js