mirror of
https://github.com/sehugg/8bitworkshop.git
synced 2024-11-21 23:30:58 +00:00
don't use WASM for Node tests until we get memory errors fixed
This commit is contained in:
parent
a208f19efe
commit
65210b39b8
@ -1,5 +1,9 @@
|
||||
"use strict";
|
||||
|
||||
var ENVIRONMENT_IS_NODE = typeof process === 'object' && typeof require === 'function';
|
||||
var ENVIRONMENT_IS_WEB = typeof window === 'object';
|
||||
var ENVIRONMENT_IS_WORKER = typeof importScripts === 'function';
|
||||
|
||||
// WebAssembly module cache
|
||||
// TODO: leaks memory even when disabled...
|
||||
var _WASM_module_cache = {};
|
||||
@ -313,7 +317,7 @@ function loadWASM(modulename, debug) {
|
||||
}
|
||||
function loadNative(modulename, debug) {
|
||||
// detect WASM
|
||||
if (typeof WebAssembly === 'object') {
|
||||
if (CACHE_WASM_MODULES && typeof WebAssembly === 'object') {
|
||||
loadWASM(modulename);
|
||||
} else {
|
||||
load(modulename);
|
||||
@ -1389,10 +1393,6 @@ function handleMessage(data) {
|
||||
console.log("Unknown message",data);
|
||||
}
|
||||
|
||||
var ENVIRONMENT_IS_NODE = typeof process === 'object' && typeof require === 'function';
|
||||
var ENVIRONMENT_IS_WEB = typeof window === 'object';
|
||||
var ENVIRONMENT_IS_WORKER = typeof importScripts === 'function';
|
||||
|
||||
if (ENVIRONMENT_IS_WORKER) {
|
||||
onmessage = function(e) {
|
||||
var result = handleMessage(e.data);
|
||||
|
@ -13,7 +13,7 @@
|
||||
"alwaysStrict": true
|
||||
},
|
||||
"include": [
|
||||
"./src/*.ts",
|
||||
"./src/**/*.ts",
|
||||
"./localForage/typings/*.ts"
|
||||
]
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user