mirror of
https://github.com/TecharoHQ/anubis.git
synced 2026-04-21 23:56:40 +00:00
chore: clean up places I forced things in testing
Signed-off-by: Xe Iaso <me@xeiaso.net>
This commit is contained in:
+4
-1
@@ -31,6 +31,9 @@ THE SOFTWARE.
|
|||||||
Includes code from https://github.com/aws/aws-sdk-js-crypto-helpers which is
|
Includes code from https://github.com/aws/aws-sdk-js-crypto-helpers which is
|
||||||
used under the terms of the Apache 2 license.
|
used under the terms of the Apache 2 license.
|
||||||
|
|
||||||
|
Includes code written in Rust and transpiled from WebAssembly to JavaScript
|
||||||
|
which is used under the terms of the licenses that comprise those crates.
|
||||||
|
|
||||||
@licend The above is the entire license notice
|
@licend The above is the entire license notice
|
||||||
for the JavaScript code in this page.
|
for the JavaScript code in this page.
|
||||||
*/'
|
*/'
|
||||||
@@ -49,7 +52,7 @@ for file in js/**/*.ts js/**/*.mjs; do
|
|||||||
|
|
||||||
mkdir -p "$(dirname "$out")"
|
mkdir -p "$(dirname "$out")"
|
||||||
|
|
||||||
esbuild "$file" --sourcemap --bundle --outfile="$out" --banner:js="$LICENSE"
|
esbuild "$file" --sourcemap --minify --bundle --outfile="$out" --banner:js="$LICENSE"
|
||||||
gzip -f -k -n "$out"
|
gzip -f -k -n "$out"
|
||||||
zstd -f -k --ultra -22 "$out"
|
zstd -f -k --ultra -22 "$out"
|
||||||
brotli -fZk "$out"
|
brotli -fZk "$out"
|
||||||
|
|||||||
@@ -13,21 +13,20 @@ interface ProcessOptions {
|
|||||||
const getHardwareConcurrency = () =>
|
const getHardwareConcurrency = () =>
|
||||||
navigator.hardwareConcurrency !== undefined ? navigator.hardwareConcurrency : 1;
|
navigator.hardwareConcurrency !== undefined ? navigator.hardwareConcurrency : 1;
|
||||||
|
|
||||||
// // https://stackoverflow.com/questions/47879864/how-can-i-check-if-a-browser-supports-webassembly
|
// https://stackoverflow.com/questions/47879864/how-can-i-check-if-a-browser-supports-webassembly
|
||||||
// const isWASMSupported = (() => {
|
const isWASMSupported = (() => {
|
||||||
// try {
|
try {
|
||||||
// if (typeof WebAssembly === "object"
|
if (typeof WebAssembly === "object"
|
||||||
// && typeof WebAssembly.instantiate === "function") {
|
&& typeof WebAssembly.instantiate === "function") {
|
||||||
// const module = new WebAssembly.Module(Uint8Array.of(0x0, 0x61, 0x73, 0x6d, 0x01, 0x00, 0x00, 0x00));
|
const module = new WebAssembly.Module(Uint8Array.of(0x0, 0x61, 0x73, 0x6d, 0x01, 0x00, 0x00, 0x00));
|
||||||
// if (module instanceof WebAssembly.Module)
|
if (module instanceof WebAssembly.Module)
|
||||||
// return new WebAssembly.Instance(module) instanceof WebAssembly.Instance;
|
return new WebAssembly.Instance(module) instanceof WebAssembly.Instance;
|
||||||
// }
|
}
|
||||||
// } catch (e) {
|
} catch (e) {
|
||||||
// return false;
|
return false;
|
||||||
// }
|
}
|
||||||
// return false;
|
return false;
|
||||||
// })();
|
})();
|
||||||
const isWASMSupported = false;
|
|
||||||
|
|
||||||
export default function process(
|
export default function process(
|
||||||
options: ProcessOptions,
|
options: ProcessOptions,
|
||||||
|
|||||||
Reference in New Issue
Block a user