Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

chore: adjusting publish configs #902

Merged
merged 20 commits into from
Apr 17, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
20 commits
Select commit Hold shift + click to select a range
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 2 additions & 0 deletions .changeset/swift-jeans-melt.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
---
---
1 change: 0 additions & 1 deletion .vscode/settings.json
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,6 @@
"editor.codeActionsOnSave": {
"source.fixAll.eslint": true
},
"typescript.preferences.autoImportFileExcludePatterns": ["index.ts"],
"files.exclude": {
"**/.git": true,
"**/.DS_Store": true,
Expand Down
8 changes: 1 addition & 7 deletions packages/abi-coder/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -6,13 +6,7 @@
"exports": {
".": "./src/index.ts"
},
"typesVersions": {
"*": {
"*": [
"./dist/*"
]
}
},
"types": "src/index.ts",
"publishConfig": {
"main": "dist/index.js",
"module": "dist/index.mjs",
Expand Down
27 changes: 22 additions & 5 deletions packages/abi-typegen/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -13,24 +13,36 @@
},
"typesVersions": {
"*": {
"*": [
"./dist/*"
"index": [
"./src/index.ts"
],
"cli": [
"./dist/cli.d.ts"
"./src/cli.ts"
],
"runTypegen": [
"./dist/runTypegen.d.ts"
"./src/runTypegen.ts"
]
}
},
"publishConfig": {
"main": "dist/index.js",
"module": "dist/index.mjs",
"types": "dist/index.d.ts",
"bin": {
"fuels-typegen": "dist/bin.js"
},
"typesVersions": {
"*": {
"index.d.ts": [
"./dist/index.d.ts"
],
"cli": [
"./dist/cli.d.ts"
],
"runTypegen": [
"./dist/runTypegen.d.ts"
]
}
},
"exports": {
".": {
"import": "./dist/index.mjs",
Expand Down Expand Up @@ -75,6 +87,11 @@
"scripts": {
"build": "tsup --dts",
"build:watch": "tsup --dts --watch",
"postbuild": "pnpm run inject:secondary:entrypoints",
"inject:secondary:entrypoints": "run-p inject:*",
"inject:configs": "echo \"import './configs.d.ts';\" >> ./dist/index.d.ts",
"inject:cli": "echo \"import './cli.d.ts';\" >> ./dist/index.d.ts",
"inject:runTypegen": "echo \"import './runTypegen.d.ts';\" >> ./dist/index.d.ts",
"pretest": "pnpm forc build -p test/fixtures/forc-projects"
}
}
8 changes: 0 additions & 8 deletions packages/abi-typegen/src/index.ts
Original file line number Diff line number Diff line change
@@ -1,11 +1,3 @@
/* eslint-disable @typescript-eslint/triple-slash-reference */

/**
* Referencing secondary entry-points
*/
/// <reference path="./cli.ts" />
/// <reference path="./runTypegen.ts" />

export * from './AbiTypeGen';

export * from './types/interfaces/IFile';
Expand Down
20 changes: 16 additions & 4 deletions packages/address/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -10,17 +10,26 @@
"typesVersions": {
"*": {
"*": [
"./dist/*"
"./src/*"
],
"configs": [
"./dist/configs.d.ts"
"./src/configs.ts"
]
}
},
"publishConfig": {
"main": "dist/index.js",
"module": "dist/index.mjs",
"types": "dist/index.d.ts",
"typesVersions": {
"*": {
"index.d.ts": [
"./dist/index.d.ts"
],
"configs": [
"./dist/configs.ts"
]
}
},
"exports": {
".": {
"import": "./dist/index.mjs",
Expand Down Expand Up @@ -51,6 +60,9 @@
"@fuel-ts/testcases": "workspace:*"
},
"scripts": {
"build": "tsup --dts"
"build": "tsup --dts",
"postbuild": "pnpm run inject:secondary:entrypoints",
"inject:secondary:entrypoints": "run-p inject:*",
"inject:configs": "echo \"import './configs.d.ts';\" >> ./dist/index.d.ts"
}
}
7 changes: 0 additions & 7 deletions packages/address/src/index.ts
Original file line number Diff line number Diff line change
@@ -1,9 +1,2 @@
/* eslint-disable @typescript-eslint/triple-slash-reference */

/**
* Referencing secondary entry-points
*/
/// <reference path="./configs.ts" />

export * from './utils';
export { default as Address } from './address';
8 changes: 1 addition & 7 deletions packages/contract/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -6,13 +6,7 @@
"exports": {
".": "./src/index.ts"
},
"typesVersions": {
"*": {
"*": [
"./dist/*"
]
}
},
"types": "src/index.ts",
"publishConfig": {
"main": "dist/index.js",
"module": "dist/index.mjs",
Expand Down
21 changes: 17 additions & 4 deletions packages/fuels/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -13,21 +13,30 @@
},
"typesVersions": {
"*": {
"*": [
"./dist/*"
"index": [
"./src/index.ts"
],
"cli": [
"./dist/cli.d.ts"
"./src/cli.ts"
]
}
},
"publishConfig": {
"main": "dist/index.js",
"module": "dist/index.mjs",
"types": "dist/index.d.ts",
"bin": {
"fuels": "dist/bin.js"
},
"typesVersions": {
"*": {
"index.d.ts": [
"./dist/index.d.ts"
],
"cli": [
"./dist/cli.d.ts"
]
}
},
"exports": {
".": {
"import": "./dist/index.mjs",
Expand Down Expand Up @@ -77,6 +86,10 @@
"scripts": {
"build": "tsup --dts",
"build:watch": "tsup --dts --watch",
"postbuild": "pnpm run inject:secondary:entrypoints",
"inject:secondary:entrypoints": "run-p inject:*",
"inject:configs": "echo \"import './configs.d.ts';\" >> ./dist/index.d.ts",
"inject:cli": "echo \"import './cli.d.ts';\" >> ./dist/index.d.ts",
"prepublishOnly": "cp ../../README.md ./README.md"
}
}
7 changes: 0 additions & 7 deletions packages/fuels/src/index.ts
Original file line number Diff line number Diff line change
@@ -1,10 +1,3 @@
/* eslint-disable @typescript-eslint/triple-slash-reference */

/**
* Referencing secondary entry-points
*/
/// <reference path="./cli.ts" />

export * from '@ethersproject/bytes';
export * from '@fuel-ts/abi-coder';
export * from '@fuel-ts/address';
Expand Down
8 changes: 1 addition & 7 deletions packages/hasher/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -6,13 +6,7 @@
"exports": {
".": "./src/index.ts"
},
"typesVersions": {
"*": {
"*": [
"./dist/*"
]
}
},
"types": "src/index.ts",
"publishConfig": {
"main": "dist/index.js",
"module": "dist/index.mjs",
Expand Down
8 changes: 1 addition & 7 deletions packages/hdwallet/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -6,13 +6,7 @@
"exports": {
".": "./src/index.ts"
},
"typesVersions": {
"*": {
"*": [
"./dist/*"
]
}
},
"types": "src/index.ts",
"publishConfig": {
"main": "dist/index.js",
"module": "dist/index.mjs",
Expand Down
8 changes: 1 addition & 7 deletions packages/interfaces/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -6,13 +6,7 @@
"exports": {
".": "./src/index.ts"
},
"typesVersions": {
"*": {
"*": [
"./dist/*"
]
}
},
"types": "src/index.ts",
"publishConfig": {
"main": "dist/index.js",
"module": "dist/index.mjs",
Expand Down
8 changes: 1 addition & 7 deletions packages/keystore/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -6,13 +6,7 @@
"exports": {
".": "./src/index.ts"
},
"typesVersions": {
"*": {
"*": [
"./dist/*"
]
}
},
"types": "src/index.ts",
"publishConfig": {
"main": "dist/index.js",
"module": "dist/index.mjs",
Expand Down
22 changes: 17 additions & 5 deletions packages/math/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -9,18 +9,27 @@
},
"typesVersions": {
"*": {
"*": [
"./dist/*"
"index": [
"./src/index.ts"
],
"configs": [
"./dist/configs.d.ts"
"./src/configs.ts"
]
}
},
"publishConfig": {
"main": "dist/index.js",
"module": "dist/index.mjs",
"types": "dist/index.d.ts",
"typesVersions": {
"*": {
"index.d.ts": [
"./dist/index.d.ts"
],
"configs": [
"./dist/configs.d.ts"
]
}
},
"exports": {
".": {
"import": "./dist/index.mjs",
Expand All @@ -39,7 +48,10 @@
],
"license": "Apache-2.0",
"scripts": {
"build": "tsup --dts"
"build": "tsup --dts",
"postbuild": "pnpm run inject:secondary:entrypoints",
"inject:secondary:entrypoints": "run-p inject:*",
"inject:configs": "echo \"import './configs.d.ts';\" >> ./dist/index.d.ts"
},
"dependencies": {
"@types/bn.js": "^5.1.1",
Expand Down
7 changes: 0 additions & 7 deletions packages/math/src/index.ts
Original file line number Diff line number Diff line change
@@ -1,10 +1,3 @@
/* eslint-disable @typescript-eslint/triple-slash-reference */

/**
* Referencing secondary entry-points
*/
/// <reference path="./configs.ts" />

export * from './bn';
export * from './decimal';
export * from './functional';
Expand Down
8 changes: 1 addition & 7 deletions packages/merkle-shared/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -6,13 +6,7 @@
"exports": {
".": "./src/index.ts"
},
"typesVersions": {
"*": {
"*": [
"./dist/*"
]
}
},
"types": "src/index.ts",
"publishConfig": {
"main": "dist/index.js",
"module": "dist/index.mjs",
Expand Down
8 changes: 1 addition & 7 deletions packages/merkle/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -6,13 +6,7 @@
"exports": {
".": "./src/index.ts"
},
"typesVersions": {
"*": {
"*": [
"./dist/*"
]
}
},
"types": "src/index.ts",
"publishConfig": {
"main": "dist/index.js",
"module": "dist/index.mjs",
Expand Down
8 changes: 1 addition & 7 deletions packages/merklesum/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -6,13 +6,7 @@
"exports": {
".": "./src/index.ts"
},
"typesVersions": {
"*": {
"*": [
"./dist/*"
]
}
},
"types": "src/index.ts",
"publishConfig": {
"main": "dist/index.js",
"module": "dist/index.mjs",
Expand Down
8 changes: 1 addition & 7 deletions packages/mnemonic/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -6,13 +6,7 @@
"exports": {
".": "./src/index.ts"
},
"typesVersions": {
"*": {
"*": [
"./dist/*"
]
}
},
"types": "src/index.ts",
"publishConfig": {
"main": "dist/index.js",
"module": "dist/index.mjs",
Expand Down
Loading