From 6d5cc8de9ab4d17986d09a575d077c41ff4cb0ca Mon Sep 17 00:00:00 2001 From: Jace Royer Date: Thu, 29 Jan 2026 11:26:34 -0600 Subject: [PATCH 1/4] feat: test native TS type building --- .gitignore | 1 + package.json | 2 +- src/utils.ts | 2 +- tsconfig.json | 8 +++++++- 4 files changed, 10 insertions(+), 3 deletions(-) diff --git a/.gitignore b/.gitignore index e1ffbad..2a02ac3 100644 --- a/.gitignore +++ b/.gitignore @@ -15,3 +15,4 @@ node_modules/ # Generated output dist +*.tsbuildinfo \ No newline at end of file diff --git a/package.json b/package.json index e7ee032..ed8c65c 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "@antimatter-dimensions/notations", - "version": "3.2.0", + "version": "3.3.0", "description": "Notations used in Antimatter Dimensions", "scripts": { "build": "npm run build:ad && npm run build:community", diff --git a/src/utils.ts b/src/utils.ts index c1dfcec..c2f1760 100644 --- a/src/utils.ts +++ b/src/utils.ts @@ -1,5 +1,5 @@ import Decimal from "break_infinity.js"; -import { Settings } from "./settings.js"; +import { Settings } from "./settings"; function commaSection(value: string, index: number): string { if (index === 0) { diff --git a/tsconfig.json b/tsconfig.json index a08bdfb..5e07f7b 100644 --- a/tsconfig.json +++ b/tsconfig.json @@ -1,4 +1,6 @@ { + "include": ["src/**/*"], + "exclude": ["src/__tests__/*"], "compilerOptions": { "target": "es5", "incremental": true, @@ -8,6 +10,10 @@ "noUnusedParameters": true, "noImplicitReturns": true, "noFallthroughCasesInSwitch": true, - "esModuleInterop": true + "esModuleInterop": true, + "declaration": true, + "emitDeclarationOnly": true, + "rootDir": "src/", + "outDir": "./dist/types" } } From 6f9adf2fc9779473b26a94a2d5b0d719b2dd3e32 Mon Sep 17 00:00:00 2001 From: Jace Royer Date: Thu, 29 Jan 2026 11:29:19 -0600 Subject: [PATCH 2/4] fix: add tsc to build script --- package.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/package.json b/package.json index ed8c65c..f835ff6 100644 --- a/package.json +++ b/package.json @@ -3,7 +3,7 @@ "version": "3.3.0", "description": "Notations used in Antimatter Dimensions", "scripts": { - "build": "npm run build:ad && npm run build:community", + "build": "tsc && npm run build:ad && npm run build:community", "build:ad": "bili --config bili.config.base.ts && cp dist/ad-notations.min.js docs/ad-notations.min.js", "build:community": "bili --config bili.config.community.ts && cp dist/ad-notations.community.min.js docs/ad-notations.community.min.js", "lint": "eslint .", From 087a7e31edbce11363f5ef30ab8d0d91028eb123 Mon Sep 17 00:00:00 2001 From: Jace Royer Date: Thu, 29 Jan 2026 11:30:06 -0600 Subject: [PATCH 3/4] fix: include types in package.json --- package.json | 1 + 1 file changed, 1 insertion(+) diff --git a/package.json b/package.json index f835ff6..ad716ac 100644 --- a/package.json +++ b/package.json @@ -13,6 +13,7 @@ "module": "dist/ad-notations.esm.js", "unpkg": "dist/ad-notations.umd.js", "jsdelivr": "dist/ad-notations.umd.js", + "types": "dist/types", "keywords": [ "notations", "numbers" From 8cd448cbcd93069ae6831fcd4710df2285be2e6a Mon Sep 17 00:00:00 2001 From: Jace Royer Date: Thu, 29 Jan 2026 11:38:29 -0600 Subject: [PATCH 4/4] Add GitHub Actions workflow for build and test --- .github/workflows/build-test.yml | 17 +++++++++++++++++ 1 file changed, 17 insertions(+) create mode 100644 .github/workflows/build-test.yml diff --git a/.github/workflows/build-test.yml b/.github/workflows/build-test.yml new file mode 100644 index 0000000..9c7ddbc --- /dev/null +++ b/.github/workflows/build-test.yml @@ -0,0 +1,17 @@ +name: Test build steps + +on: + release: + types: [published] + +jobs: + build: + + runs-on: ubuntu-latest + + steps: + - uses: actions/checkout@master + - uses: actions/setup-node@v1 + - run: npm install + - run: npm run build +