diff options
author | toasted-nutbread <toasted-nutbread@users.noreply.github.com> | 2022-10-16 22:07:57 -0400 |
---|---|---|
committer | GitHub <noreply@github.com> | 2022-10-16 22:07:57 -0400 |
commit | 096bde44eea85f1c0cc2cc6d37b27559b3404a7a (patch) | |
tree | 75fbcadcc8c5367b862532dc15e17a0ec65442a7 /ext/js/background/backend.js | |
parent | a47cbc39e24f0aa2a64e7e787657a0a777d11edb (diff) |
Documentation updates (#2257)
* Document Backend
* Document RequestBuilder
* Document some of AnkiConnect
Diffstat (limited to 'ext/js/background/backend.js')
-rw-r--r-- | ext/js/background/backend.js | 11 |
1 files changed, 11 insertions, 0 deletions
diff --git a/ext/js/background/backend.js b/ext/js/background/backend.js index 2154b32a..b156e16f 100644 --- a/ext/js/background/backend.js +++ b/ext/js/background/backend.js @@ -38,7 +38,14 @@ * wanakana */ +/** + * This class controls the core logic of the extension, including API calls + * and various forms of communication between browser tabs and external applications. + */ class Backend { + /** + * Creates a new instance. + */ constructor() { this._japaneseUtil = new JapaneseUtil(wanakana); this._environment = new Environment(); @@ -145,6 +152,10 @@ class Backend { ]); } + /** + * Initializes the instance. + * @returns {Promise<void>} A promise which is resolved when initialization completes. + */ prepare() { if (this._preparePromise === null) { const promise = this._prepareInternal(); |