diff options
Diffstat (limited to 'api/yomikun.ts')
-rw-r--r-- | api/yomikun.ts | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/api/yomikun.ts b/api/yomikun.ts index 60d49ba..a7f214e 100644 --- a/api/yomikun.ts +++ b/api/yomikun.ts @@ -5,9 +5,15 @@ import Sentence from "./sentence.ts"; export default class Yomikun { protected core: Core; + public ready: Promise<void>; constructor(core?: Core) { this.core = core ?? new RemoteCoreClient(); + + this.ready = new Promise(async resolve => { + await this.core.ready; + resolve(); + }) } async sentence(input: string): Promise<Sentence> { |