Use WASM workers for even smaller size

This commit is contained in:
msqr1
2024-08-29 20:43:21 -07:00
parent c72ce7a829
commit 01a0dbf3a7
12 changed files with 71 additions and 75 deletions

View File

@@ -147,7 +147,4 @@ Module.createRecognizerWithSpkModel = (model, sampleRate, spkModel) => {
Module.createRecognizerWithGrm = (model, sampleRate, grammar) => {
return Recognizer.create(model.obj, sampleRate, 3, grammar, null)
}
// See Emscripten issue #21937
if (!ENVIRONMENT_IS_PTHREAD) Module['mainScriptUrlOrBlob'] = new Blob([`importScripts('${_scriptName}')`], { type : "text/javascript" })
}