Skip to content

Commit

Permalink
Merge pull request #39 from diego-aquino/@diego-aquino/38-explicit-ty…
Browse files Browse the repository at this point in the history
…pe-definitions

fix: explicit type definitions (#38)
  • Loading branch information
diego-aquino authored Jan 27, 2024
2 parents 24cf56a + 00c106d commit 82849d7
Show file tree
Hide file tree
Showing 22 changed files with 31 additions and 20 deletions.
1 change: 0 additions & 1 deletion .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,6 @@ node_modules
/apps/*/out
/packages/*/dist
/packages/*/build
/packages/*/*.d.ts

# Test coverage
/apps/*/tests/coverage
Expand Down
2 changes: 0 additions & 2 deletions .prettierignore
Original file line number Diff line number Diff line change
Expand Up @@ -8,9 +8,7 @@ apps/*/build
apps/*/public/mockServiceWorker.js
packages/*/dist
packages/*/build
packages/*/*.d.ts
packages/*/public/mockServiceWorker.js
packages/zimic/interceptor/*.d.ts

# Tests
/apps/*/tests/coverage
Expand Down
File renamed without changes.
1 change: 0 additions & 1 deletion apps/zimic-test-client/.eslintignore
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,6 @@ node_modules

# Build
/dist
/*.d.ts
/public/mockServiceWorker.js

# Tests
Expand Down
2 changes: 1 addition & 1 deletion apps/zimic-test-client/tsconfig.json
Original file line number Diff line number Diff line change
Expand Up @@ -9,5 +9,5 @@
}
},
"include": ["**/*.ts", "**/*.mts"],
"exclude": ["node_modules", "dist", "*.d.ts"]
"exclude": ["node_modules", "dist"]
}
2 changes: 1 addition & 1 deletion apps/zimic-test-client/turbo.json
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
"pipeline": {
"build": {
"inputs": ["src/**/*.{ts,json}", "{package,tsconfig}.json", "tsup.config.ts", ".swcrc"],
"outputs": ["dist/**", "*.d.ts"]
"outputs": ["dist/**"]
},

"test:turbo": {
Expand Down
1 change: 0 additions & 1 deletion packages/release/.eslintignore
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,6 @@ node_modules

# Build
/dist
/*.d.ts

# Tests
/tests/coverage
Expand Down
1 change: 1 addition & 0 deletions packages/release/cli.d.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
export * from './dist/cli';
1 change: 1 addition & 0 deletions packages/release/index.d.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
export * from './dist/index';
5 changes: 3 additions & 2 deletions packages/release/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,8 @@
"private": false,
"files": [
"dist",
"*.d.ts"
"index.d.ts",
"cli.d.ts"
],
"exports": {
".": "./dist/index.js"
Expand All @@ -15,7 +16,7 @@
"scripts": {
"dev": "pnpm build --watch",
"dev:cli": "tsx src/cli/index.ts",
"build": "tsup && rm -rf *.d.ts && cp ./dist/*.d.ts .",
"build": "tsup",
"lint": "eslint --ext 'ts,tsx' --cache --no-error-on-unmatched-pattern --fix",
"lint:turbo": "pnpm lint . --max-warnings 0",
"style": "prettier --log-level warn --ignore-unknown --no-error-on-unmatched-pattern --cache",
Expand Down
2 changes: 1 addition & 1 deletion packages/release/tsconfig.json
Original file line number Diff line number Diff line change
Expand Up @@ -9,5 +9,5 @@
}
},
"include": ["**/*.ts", "**/*.mts"],
"exclude": ["node_modules", "dist", "*.d.ts"]
"exclude": ["node_modules", "dist"]
}
2 changes: 1 addition & 1 deletion packages/release/turbo.json
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
"pipeline": {
"build": {
"inputs": ["src/**/*.{ts,json}", "{package,tsconfig}.json", "tsup.config.ts", ".swcrc"],
"outputs": ["dist/**", "*.d.ts"]
"outputs": ["dist/**"]
},

"test:turbo": {
Expand Down
2 changes: 0 additions & 2 deletions packages/zimic/.eslintignore
Original file line number Diff line number Diff line change
Expand Up @@ -7,8 +7,6 @@ node_modules

# Build
/dist
/*.d.ts
/interceptor/*.d.ts
/public/mockServiceWorker.js

# Tests
Expand Down
1 change: 0 additions & 1 deletion packages/zimic/.gitignore
Original file line number Diff line number Diff line change
@@ -1,2 +1 @@
/interceptor/*.d.ts
/public/mockServiceWorker.js
1 change: 0 additions & 1 deletion packages/zimic/.prettierignore
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,6 @@ tsconfig.tsbuildinfo

# Build
/dist
/interceptor/*.d.ts
/public/mockServiceWorker.js

# Tests
Expand Down
1 change: 1 addition & 0 deletions packages/zimic/index.d.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
export * from './dist/index';
1 change: 1 addition & 0 deletions packages/zimic/interceptor.d.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
export * from './dist/interceptor';
1 change: 1 addition & 0 deletions packages/zimic/interceptor/browser.d.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
export * from '../dist/interceptor/browser';
1 change: 1 addition & 0 deletions packages/zimic/interceptor/node.d.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
export * from '../dist/interceptor/node';
19 changes: 16 additions & 3 deletions packages/zimic/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -26,10 +26,23 @@
},
"license": "MIT",
"files": [
"dist"
"package.json",
"README.md",
"LICENSE.md",
"dist",
"index.d.ts",
"interceptor.d.ts",
"interceptor/node.d.ts",
"interceptor/browser.d.ts"
],
"types": "dist/index.d.ts",
"types": "index.d.ts",
"exports": {
".": {
"import": "./dist/index.mjs",
"require": "./dist/index.js",
"default": "./dist/index.js",
"types": "./dist/index.d.ts"
},
"./interceptor": {
"import": "./dist/interceptor.mjs",
"require": "./dist/interceptor.js",
Expand All @@ -56,7 +69,7 @@
},
"scripts": {
"dev": "pnpm build --watch",
"build": "tsup && rm -rf *.d.ts && cp ./dist/*.d.ts . && mkdir -p ./interceptor && rm -rf ./interceptor/*.d.ts && cp ./dist/interceptor/*.d.ts ./interceptor",
"build": "tsup",
"lint": "eslint --ext 'ts,tsx' --cache --no-error-on-unmatched-pattern --fix",
"lint:turbo": "pnpm lint . --max-warnings 0",
"style": "prettier --log-level warn --ignore-unknown --no-error-on-unmatched-pattern --cache",
Expand Down
2 changes: 1 addition & 1 deletion packages/zimic/tsconfig.json
Original file line number Diff line number Diff line change
Expand Up @@ -10,5 +10,5 @@
}
},
"include": ["**/*.ts", "**/*.mts"],
"exclude": ["node_modules", "dist", "*.d.ts"]
"exclude": ["node_modules", "dist"]
}
2 changes: 1 addition & 1 deletion packages/zimic/turbo.json
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
"pipeline": {
"build": {
"inputs": ["src/**/*.{ts,json}", "{package,tsconfig}.json", "tsup.config.ts", ".swcrc"],
"outputs": ["dist/**", "*.d.ts", "interceptor/*.d.ts"]
"outputs": ["dist/**"]
},

"test:turbo": {
Expand Down

0 comments on commit 82849d7

Please sign in to comment.