Update main entry and tsconfig for JS support

Changed package.json main and exports to use index.js instead of index.cjs. Updated tsconfig.json to allow JavaScript files and expanded include patterns to support both JS and TS files.
This commit is contained in:
手瓜一十雪 committed 2025-11-15 16:09:26 +08:00
1 parent ef63812391
commit 1990761ad6
2 files changed
+10 -3

No files matched your search

+2 -2
View File
@@ -3,13 +3,13 @@
"version": "0.0.1",
"private": true,
"type": "module",
"main": "index.cjs",
"main": "index.js",
"scripts": {
"dev": "powershell ./nodeTest.ps1"
},
"exports": {
".": {
"require": "./index.cjs"
"require": "./index.js"
},
"./*": {
"require": "./*"
+8 -1
View File
@@ -1,7 +1,14 @@
{
"extends": "../../tsconfig.base.json",
"compilerOptions": {
"allowJs": true
},
"include": [
"**/*.cjs"
"*.cjs",
"**/*.cjs",
"**/*.ts",
"*.js",
"**/*.js"
],
"exclude": [
"node_modules",