From dcc9e96ec910200764ee15729206a37cf523b1bc Mon Sep 17 00:00:00 2001 From: Jonathan Tang Date: Sat, 12 Jun 2021 12:02:22 +0100 Subject: [PATCH] Export isInitialized from onigasmH --- src/index.ts | 4 ++-- src/onigasmH.ts | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/src/index.ts b/src/index.ts index ef27db1..db281fa 100644 --- a/src/index.ts +++ b/src/index.ts @@ -1,6 +1,6 @@ -import { loadWASM } from './onigasmH' +import { isInitialized, loadWASM } from './onigasmH' import OnigRegExp, { IOnigSearchResult } from './OnigRegExp' import OnigScanner, { IOnigCaptureIndex } from './OnigScanner' import OnigString from './OnigString' -export { loadWASM, OnigScanner, OnigRegExp, OnigString, IOnigCaptureIndex, IOnigSearchResult } +export { isInitialized, loadWASM, OnigScanner, OnigRegExp, OnigString, IOnigCaptureIndex, IOnigSearchResult } diff --git a/src/onigasmH.ts b/src/onigasmH.ts index 8a81cdc..bb78a11 100644 --- a/src/onigasmH.ts +++ b/src/onigasmH.ts @@ -42,7 +42,7 @@ async function initModule(bytes: ArrayBuffer) { }) } -let isInitialized = false +export let isInitialized = false /** * Mount the .wasm file that will act as library's "backend"