Simplify and fix TypeScript compilation output (#7815)

* Simplify and fix TypeScript compilation output

* Revert deps upgrade
This commit is contained in:
Björn Harrtell 2023-02-06 22:10:20 +01:00 committed by GitHub
parent f3a3f45159
commit 85aee1f5c3
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
5 changed files with 8 additions and 18 deletions

View File

@ -11,18 +11,6 @@
],
"main": "js/flatbuffers.js",
"module": "mjs/flatbuffers.js",
"exports": {
".": {
"node": {
"import": "./mjs/flatbuffers.js",
"require": "./js/flatbuffers.js"
},
"default": "./js/flatbuffers.js"
},
"./js/flexbuffers.js": {
"default": "./js/flexbuffers.js"
}
},
"directories": {
"doc": "docs",
"test": "tests"

View File

@ -126,7 +126,9 @@ NODE_CMD = ["node"]
print("Running TypeScript Tests...")
check_call(NODE_CMD + ["JavaScriptTest"])
check_call(NODE_CMD + ["JavaScriptTestv1.cjs", "./monster_test_generated.cjs"])
check_call(NODE_CMD + ["JavaScriptUnionVectorTest"])
check_call(NODE_CMD + ["JavaScriptFlexBuffersTest"])
check_call(NODE_CMD + ["JavaScriptComplexArraysTest"])
print("Running old v1 TypeScript Tests...")
check_call(NODE_CMD + ["JavaScriptTestv1.cjs", "./monster_test_generated.cjs"])

View File

@ -1,7 +1,7 @@
{
"compilerOptions": {
"target": "ES2020",
"module": "CommonJS",
"target": "es2020",
"module": "commonjs",
"lib": ["ES2020", "DOM"],
"declaration": true,
"outDir": "./js",

View File

@ -1,7 +1,7 @@
{
"compilerOptions": {
"target": "ES2020",
"module": "NodeNext",
"target": "es2020",
"module": "es2020",
"lib": ["ES2020", "DOM"],
"declaration": true,
"outDir": "./mjs",

View File

@ -1169,4 +1169,4 @@ yallist@^4.0.0:
yocto-queue@^0.1.0:
version "0.1.0"
resolved "https://registry.yarnpkg.com/yocto-queue/-/yocto-queue-0.1.0.tgz#0294eb3dee05028d31ee1a5fa2c556a6aaf10a1b"
integrity sha512-rVksvsnNCdJ/ohGc6xgPwyN8eheCxsiLM8mxuE/t/mOVqJewPuO1miLpTHQiRgTKCLexL4MeAFVagts7HmNZ2Q==
integrity sha512-rVksvsnNCdJ/ohGc6xgPwyN8eheCxsiLM8mxuE/t/mOVqJewPuO1miLpTHQiRgTKCLexL4MeAFVagts7HmNZ2Q==