Skip to content

Commit 54143d1

Browse files
committed
chore: rename node-binding entry name
1 parent 3547411 commit 54143d1

File tree

5 files changed

+8
-9
lines changed

5 files changed

+8
-9
lines changed

.gitignore

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@ prebuilds/
99
.rollup.cache
1010

1111
index.js
12-
index.d.ts
12+
*.d.ts
1313
index.js.map
1414
tsconfig.tsbuildinfo
1515

package.json

Lines changed: 5 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -16,10 +16,10 @@
1616
"native.build:debug": "node-gyp configure --debug && node-gyp build --debug",
1717
"native.prebuild": "prebuildify --napi -t 12.0.0 -t [email protected] -t [email protected] --strip",
1818
"native.prebuild-ia32": "prebuildify --napi --arch=ia32 -t 12.0.0 -t [email protected] -t [email protected] --strip",
19-
"js.clean": "shx rm -rf dist dist-test .rollup.cache .parcel-cache **/tsconfig.tsbuildinfo ./index.js ./index.js.map ./index.d.ts",
19+
"js.clean": "shx rm -rf dist dist-test .rollup.cache .parcel-cache **/tsconfig.tsbuildinfo ./index.* ./*.d.ts",
2020
"js.dev": "npm run js.types && cross-env NODE_ENV=development rollup -c -w",
2121
"js.build": "npm run js.types && cross-env NODE_ENV=production rollup -c",
22-
"js.types": "(tsc -p ./src/binding/tsconfig.json --emitDeclarationOnly) && (shx mv ./src/binding/node.d.ts index.d.ts)",
22+
"js.types": "tsc -p ./src/binding/tsconfig.json --emitDeclarationOnly && shx mv ./src/binding/*.d.ts .",
2323
"clean": "npm run native.clean && npm run js.clean",
2424
"install": "node-gyp-build",
2525
"build": "npm run native.build && npm run js.build",
@@ -31,15 +31,14 @@
3131
"benchmark": "npm run benchmark.small && npm run benchmark.regular && npm run benchmark.large && npm run benchmark.tree",
3232
"examples.cpp": "cmake -S . -B ./build && cmake --build ./build --config Debug",
3333
"bump": "ncu -u --greatest",
34-
"prepare": "npm run build"
34+
"prepare": "npm run js.clean && npm run build"
3535
},
3636
"prettier": "prettier-config-atomic",
3737
"files": [
3838
"src",
3939
"prebuilds",
40-
"index.js",
41-
"index.d.ts",
42-
"index.js.map",
40+
"index.*",
41+
"*.d.ts",
4342
"binding.gyp"
4443
],
4544
"gypfile": true,

rollup.config.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@ const plugins = createPlugins(["ts", "js"])
44

55
const RollupConfig = [
66
{
7-
input: "src/binding/node.ts",
7+
input: "src/binding/index.ts",
88
output: [
99
{
1010
file: "./index.js",

src/binding/binding.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
import type { Tree, TreeFilterResult } from "./node"
1+
import type { Tree, TreeFilterResult } from "./index"
22

33
export declare class Zadeh {
44
constructor()
File renamed without changes.

0 commit comments

Comments
 (0)