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

fix: restore missing exports declarations #3892

Merged
merged 13 commits into from
Jul 28, 2022
Merged
69 changes: 69 additions & 0 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

10 changes: 5 additions & 5 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -3,11 +3,11 @@
"name": "query",
"repository": "https://github.com/tanstack/query.git",
"scripts": {
"clean": "npm exec --workspaces -c \"rm -rf build || true\"",
"clean": "lerna run clean --stream --no-bail",
"install:csb": "npm install --frozen-lockfile && node ./scripts/fix-package-json.js",
"test": "(is-ci && npm run test:ci) || npm run test:dev",
"test:ci": "npm run compile && npm run test:format && npm run test:eslint && npm run test:jest",
"test:dev": "npm run compile && npm run test:format && npm run test:eslint && npm run test:jest:dev",
"test:ci": "npm run typecheck && npm run test:format && npm run test:eslint && npm run test:jest",
"test:dev": "npm run typecheck && npm run test:format && npm run test:eslint && npm run test:jest:dev",
"test:dev:17": "REACTJS_VERSION=17 jest --watch",
"test:eslint": "lerna run test:eslint --stream --no-bail",
"test:format": "npm run prettier -- --check",
Expand All @@ -23,8 +23,7 @@
"prettier": "prettier \"packages/*/{src/**,examples/**/src/**}.{md,js,jsx,ts,tsx,json}\"",
"prettier:write": "npm run prettier -- --write",
"visualize": "lerna exec 'open build/stats-html.html'",
"cipublish": "ts-node scripts/publish.ts",
"compile": "lerna run compile --stream --no-bail"
"cipublish": "ts-node scripts/publish.ts"
},
"namespace": "@tanstack",
"workspaces": [
Expand Down Expand Up @@ -64,6 +63,7 @@
"@commitlint/parse": "^16.2.1",
"@faker-js/faker": "^6.3.1",
"@rollup/plugin-babel": "^5.3.1",
"@rollup/plugin-commonjs": "22.0.1",
"@rollup/plugin-node-resolve": "^13.2.1",
"@rollup/plugin-replace": "^4.0.0",
"@testing-library/jest-dom": "^5.16.4",
Expand Down
2 changes: 1 addition & 1 deletion packages/query-async-storage-persister/.eslintrc
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"parserOptions": {
"project": "./tsconfig.json",
"project": "./tsconfig.lint.json",
"sourceType": "module"
}
}
21 changes: 15 additions & 6 deletions packages/query-async-storage-persister/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -10,16 +10,25 @@
"type": "github",
"url": "https://github.com/sponsors/tannerlinsley"
},
"module": "build/esm/index.js",
"main": "build/cjs/index.js",
"module": "build/lib/index.mjs",
"main": "build/lib/index.js",
"browser": "build/umd/index.production.js",
"types": "build/types/packages/query-async-storage-persister/src/index.d.ts",
"types": "build/lib/index.d.ts",
"exports": {
".": {
"types": "./build/lib/index.d.ts",
"import": "./build/lib/index.mjs",
"default": "./build/lib/index.js"
},
"./package.json": "./package.json"
},
"files": [
"build/*",
"build/lib/*",
"build/umd/*",
"src"
],
"scripts": {
"test:eslint": "../../node_modules/.bin/eslint --ext .ts,.tsx ./src",
"compile": "../../node_modules/.bin/tsc -p tsconfig.json --noEmit --emitDeclarationOnly false"
"clean": "rm -rf ./build",
"test:eslint": "../../node_modules/.bin/eslint --ext .ts,.tsx ./src"
}
}
14 changes: 10 additions & 4 deletions packages/query-async-storage-persister/tsconfig.json
Original file line number Diff line number Diff line change
@@ -1,9 +1,15 @@
{
"composite": true,
"extends": "../../tsconfig.base.json",
"compilerOptions": {
"outDir": "./build/types"
"composite": true,
"rootDir": "./src",
"outDir": "./build/lib",
"tsBuildInfoFile": "./build/.tsbuildinfo"
},
"files": ["src/index.ts"],
"include": ["src"]
"include": ["src"],
"exclude": ["src/__tests__"],
"references": [
{ "path": "../query-core" },
{ "path": "../react-query-persist-client" }
]
}
14 changes: 14 additions & 0 deletions packages/query-async-storage-persister/tsconfig.lint.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
{
"extends": "../../tsconfig.base.json",
"compilerOptions": {
"composite": true,
"rootDir": "./src",
"outDir": "./build/lib",
"tsBuildInfoFile": "./build/.tsbuildinfo"
},
"include": ["src"],
"references": [
{ "path": "../query-core" },
{ "path": "../react-query-persist-client" }
]
}
2 changes: 1 addition & 1 deletion packages/query-broadcast-client-experimental/.eslintrc
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"parserOptions": {
"project": "./tsconfig.json",
"project": "./tsconfig.lint.json",
"sourceType": "module"
}
}
21 changes: 15 additions & 6 deletions packages/query-broadcast-client-experimental/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -10,17 +10,26 @@
"type": "github",
"url": "https://github.com/sponsors/tannerlinsley"
},
"module": "build/esm/index.js",
"main": "build/cjs/packages/query-broadcast-client-experimental/src/index.js",
"module": "build/lib/index.mjs",
"main": "build/lib/index.js",
"browser": "build/umd/index.production.js",
"types": "build/types/query-broadcast-client-experimental/src/index.d.ts",
"types": "build/lib/index.d.ts",
"exports": {
".": {
"types": "./build/lib/index.d.ts",
"import": "./build/lib/index.mjs",
"default": "./build/lib/index.js"
},
"./package.json": "./package.json"
},
"files": [
"build/*",
"build/lib/*",
"build/umd/*",
"src"
],
"scripts": {
"test:eslint": "../../node_modules/.bin/eslint --ext .ts,.tsx ./src",
"compile": "../../node_modules/.bin/tsc -p tsconfig.json --noEmit --emitDeclarationOnly false"
"clean": "rm -rf ./build",
"test:eslint": "../../node_modules/.bin/eslint --ext .ts,.tsx ./src"
},
"dependencies": {
"broadcast-channel": "^3.4.1"
Expand Down
11 changes: 7 additions & 4 deletions packages/query-broadcast-client-experimental/tsconfig.json
Original file line number Diff line number Diff line change
@@ -1,9 +1,12 @@
{
"composite": true,
"extends": "../../tsconfig.base.json",
"compilerOptions": {
"outDir": "./build/types"
"composite": true,
"rootDir": "./src",
"outDir": "./build/lib",
"tsBuildInfoFile": "./build/.tsbuildinfo"
},
"files": ["src/index.ts"],
"include": ["src"]
"include": ["src"],
"exclude": ["src/__tests__"],
"references": [{ "path": "../query-core" }]
}
11 changes: 11 additions & 0 deletions packages/query-broadcast-client-experimental/tsconfig.lint.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
{
"extends": "../../tsconfig.base.json",
"compilerOptions": {
"composite": true,
"rootDir": "./src",
"outDir": "./build/lib",
"tsBuildInfoFile": "./build/.tsbuildinfo"
},
"include": ["src"],
"references": [{ "path": "../query-core" }]
}
25 changes: 0 additions & 25 deletions packages/query-broadcast-client-experimental/yarn.lock

This file was deleted.

2 changes: 1 addition & 1 deletion packages/query-core/.eslintrc
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"parserOptions": {
"project": "./tsconfig.json",
"project": "./tsconfig.lint.json",
"sourceType": "module"
}
}
21 changes: 15 additions & 6 deletions packages/query-core/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -10,16 +10,25 @@
"type": "github",
"url": "https://github.com/sponsors/tannerlinsley"
},
"module": "build/esm/index.js",
"main": "build/cjs/index.js",
"module": "build/lib/index.mjs",
"main": "build/lib/index.js",
"browser": "build/umd/index.production.js",
"types": "build/types/packages/query-core/src/index.d.ts",
"types": "build/lib/index.d.ts",
"exports": {
".": {
"types": "./build/lib/index.d.ts",
"import": "./build/lib/index.mjs",
"default": "./build/lib/index.js"
},
"./package.json": "./package.json"
},
"files": [
"build/*",
"build/lib/*",
"build/umd/*",
"src"
],
"scripts": {
"test:eslint": "../../node_modules/.bin/eslint --ext .ts,.tsx ./src",
"compile": "../../node_modules/.bin/tsc -p tsconfig.json --noEmit --emitDeclarationOnly false"
"clean": "rm -rf ./build",
"test:eslint": "../../node_modules/.bin/eslint --ext .ts,.tsx ./src"
}
}
4 changes: 2 additions & 2 deletions packages/query-core/src/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -17,13 +17,13 @@ export {
parseMutationFilterArgs,
parseMutationArgs,
} from './utils'
export type { MutationFilters, QueryFilters } from './utils'
export type { MutationFilters, QueryFilters, Updater } from './utils'
export { isCancelledError } from './retryer'
export { dehydrate, hydrate } from './hydration'

// Types
export * from './types'
export type { Query } from './query'
export type { Query, QueryState } from './query'
export type { Mutation } from './mutation'
export type { Logger } from './logger'
export type {
Expand Down
10 changes: 6 additions & 4 deletions packages/query-core/tsconfig.json
Original file line number Diff line number Diff line change
@@ -1,9 +1,11 @@
{
"composite": true,
"extends": "../../tsconfig.base.json",
"compilerOptions": {
"outDir": "./build/types"
"composite": true,
"rootDir": "./src",
"outDir": "./build/lib",
"tsBuildInfoFile": "./build/.tsbuildinfo"
},
"files": ["src/index.ts"],
"include": ["src"]
"include": ["src"],
"exclude": ["src/tests"]
}
10 changes: 10 additions & 0 deletions packages/query-core/tsconfig.lint.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
{
"extends": "../../tsconfig.base.json",
"compilerOptions": {
"composite": true,
"rootDir": "./src",
"outDir": "./build/lib",
"tsBuildInfoFile": "./build/.tsbuildinfo"
},
"include": ["src"]
}
2 changes: 1 addition & 1 deletion packages/query-sync-storage-persister/.eslintrc
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"parserOptions": {
"project": "./tsconfig.json",
"project": "./tsconfig.lint.json",
"sourceType": "module"
}
}
Loading