@data-client/test
Version:
Testing utilities for Data Client
173 lines (172 loc) • 5.61 kB
JSON
{
"name": "@data-client/test",
"version": "0.14.22",
"description": "Testing utilities for Data Client",
"homepage": "https://dataclient.io/docs/guides/storybook",
"repository": {
"type": "git",
"url": "git+ssh://git@github.com:reactive/data-client.git",
"directory": "packages/test"
},
"bugs": {
"url": "https://github.com/reactive/data-client/issues"
},
"keywords": [
"testing",
"storybook",
"hooks",
"react",
"data",
"cache",
"flux",
"suspense",
"fetch",
"hook",
"networking",
"concurrent mode",
"typescript",
"redux",
"data fetching",
"data cache",
"normalized cache",
"async",
"swr"
],
"sideEffects": false,
"main": "dist/index.js",
"react-native": "legacy/browser.js",
"module": "legacy/browser.js",
"types": "lib/index.d.ts",
"typesVersions": {
">=4.0": {
"": [
"lib/index.d.ts"
],
"browser": [
"lib/browser.d.ts"
],
"*": [
"lib/index.d.ts"
]
},
">=3.4": {
"": [
"ts3.4/index.d.ts"
],
"browser": [
"ts3.4/browser.d.ts"
],
"*": [
"ts3.4/index.d.ts"
]
}
},
"exports": {
".": {
"node": {
"module": "./lib/index.js",
"import": "./node.mjs",
"require": "./dist/index.js"
},
"module": "./lib/browser.js",
"import": "./node.mjs",
"require": "./dist/index.js",
"browser": "./lib/browser.js",
"react-native": "./native/browser.js",
"default": "./lib/index.js"
},
"./browser": {
"default": "./lib/browser.js"
},
"./package.json": "./package.json"
},
"type": "module",
"engines": {
"node": "^12.17 || ^13.7 || >=14"
},
"files": [
"src",
"dist",
"lib",
"ts3.4",
"node.mjs",
"legacy",
"native",
"LICENSE",
"README.md"
],
"scripts": {
"build:lib": "run build:lib:esm && run build:lib:cjs",
"build:lib:esm": "NODE_ENV=production BROWSERSLIST_ENV='2020' POLYFILL_TARGETS='chrome>88,safari>14' yarn g:babel-lite --out-dir lib --extensions '.ts,.tsx,.js'",
"build:lib:cjs": "BROWSERSLIST_ENV=node12 BABEL_MODULES=cjs yarn g:babel-lite --out-dir lib --extensions '.cts' && mv ./lib/makeRenderDataClient/renderHook.js ./lib/makeRenderDataClient/renderHook.cjs && mv ./lib/makeRenderDataClient/use18.js ./lib/makeRenderDataClient/use18.cjs && mv ./lib/makeRenderDataClient/use18.native.js ./lib/makeRenderDataClient/use18.native.cjs",
"build:native:esm": "COMPILE_TARGET=native NODE_ENV=production BROWSERSLIST_ENV='hermes12' yarn g:babel --out-dir native --extensions '.ts,.tsx,.js'",
"build:legacy:lib": "run build:legacy:lib:esm && run build:legacy:lib:cjs",
"build:legacy:lib:esm": "NODE_ENV=production BROWSERSLIST_ENV='2018' POLYFILL_TARGETS='chrome>80,safari>13,firefox>72' yarn g:babel-lite --out-dir legacy --extensions '.ts,.tsx,.js'",
"build:legacy:lib:cjs": "BABEL_MODULES=cjs BROWSERSLIST_ENV='2018' POLYFILL_TARGETS='chrome>80,safari>13,firefox>72' yarn g:babel-lite --out-dir legacy --extensions '.cts' && mv ./legacy/makeRenderDataClient/renderHook.js ./legacy/makeRenderDataClient/renderHook.cjs && mv ./legacy/makeRenderDataClient/use18.js ./legacy/makeRenderDataClient/use18.cjs && mv ./legacy/makeRenderDataClient/use18.native.js ./legacy/makeRenderDataClient/use18.native.cjs",
"build:bundle": "BROWSERSLIST_ENV=node12 yarn g:rollup && COMPILE_TARGET=native BROWSERSLIST_ENV=hermes12 yarn g:rollup && echo '{\"type\":\"commonjs\"}' > dist/package.json",
"build:clean": "yarn g:clean native",
"build:legacy-types": "yarn g:downtypes lib ts3.4",
"build": "run build:lib && run build:legacy:lib && run build:native:esm && run build:bundle",
"dev": "run build:lib:esm -w & run build:lib:cjs -w && fg",
"prepare": "run build:lib",
"prepack": "echo 'run prepack' && run prepare && run build:bundle && run build:legacy:lib"
},
"author": "Nathaniel Tucker <me@ntucker.me> (https://github.com/ntucker)",
"funding": "https://github.com/sponsors/ntucker",
"license": "Apache-2.0",
"dependencies": {
"@babel/runtime": "^7.20.0",
"@testing-library/dom": "^10.1.0",
"@testing-library/react": "^16.0.0",
"@testing-library/react-native": "^13.0.0"
},
"peerDependencies": {
"@data-client/react": "^0.12.15 || ^0.13.0 || ^0.14.0",
"@testing-library/react-hooks": "^8.0.0",
"@types/react": "^16.14.0 || ^17.0.0 || ^18.0.0 || ^19.0.0-0 || ^19.0.0",
"@types/react-dom": "*",
"jest": "*",
"react": "^16.14.0 || ^17.0.0 || ^18.0.0 || ^19.0.0-0 || ^19.0.0",
"react-dom": "*",
"react-native": "*",
"react-test-renderer": "*"
},
"peerDependenciesMeta": {
"@testing-library/react-hooks": {
"optional": true
},
"@types/react": {
"optional": true
},
"@types/react-dom": {
"optional": true
},
"jest": {
"optional": true
},
"react-dom": {
"optional": true
},
"react-native": {
"optional": true
},
"react-test-renderer": {
"optional": true
}
},
"devDependencies": {
"@anansi/browserslist-config": "^1.4.2",
"@data-client/react": "workspace:*",
"@types/jest": "^29.5.0",
"@types/node": "^22.0.0",
"@types/react": "19.0.10",
"@types/react-dom": "19.0.4",
"@types/react-test-renderer": "19.0.0",
"jest": "^29.5.0",
"react": "19.0.0",
"react-dom": "19.0.0",
"react-native": "*",
"react-test-renderer": "*",
"rollup-plugins": "workspace:*"
}
}