File tree 3 files changed +9
-12
lines changed
packages/react-query-devtools 3 files changed +9
-12
lines changed Original file line number Diff line number Diff line change 15
15
"test:jest:dev" : " jest --config ./jest.config.ts --watch" ,
16
16
"test:size" : " npm run build && bundlewatch" ,
17
17
"build" : " rollup --config rollup.config.js && npm run typecheck" ,
18
+ "postbuild" : " cp ./packages/react-query-devtools/src/noop.ts ./packages/react-query-devtools/build/esm/noop.js" ,
18
19
"typecheck" : " tsc -b" ,
19
20
"watch" : " concurrently --kill-others \" rollup --config rollup.config.js -w\" \" npm run typecheck -- --watch\" \" npm run test\" " ,
20
21
"linkAll" : " lerna exec 'npm run link' --parallel" ,
Original file line number Diff line number Diff line change 10
10
"type" : " github" ,
11
11
"url" : " https://github.com/sponsors/tannerlinsley"
12
12
},
13
+ "module" : " build/esm/index.js" ,
13
14
"main" : " build/cjs/packages/react-query-devtools/src/index.js" ,
14
15
"browser" : " build/umd/index.production.js" ,
15
16
"types" : " build/types/react-query-devtools/src/index.d.ts" ,
16
17
"files" : [
17
18
" build/*" ,
18
19
" src"
19
20
],
21
+ "exports" : {
22
+ "development" : {
23
+ "default" : " ./build/esm/index.js"
24
+ },
25
+ "default" : " ./build/esm/noop.js"
26
+ },
20
27
"scripts" : {
21
28
"test:eslint" : " ../../node_modules/.bin/eslint --ext .ts,.tsx ./src" ,
22
29
"compile" : " ../../node_modules/.bin/tsc -p tsconfig.json --noEmit --emitDeclarationOnly false"
Original file line number Diff line number Diff line change 1
- if ( process . env . NODE_ENV !== 'development' ) {
2
- module . exports = {
3
- ReactQueryDevtools : function ( ) {
4
- return null
5
- } ,
6
- ReactQueryDevtoolsPanel : function ( ) {
7
- return null
8
- } ,
9
- }
10
- } else {
11
- module . exports = require ( './devtools' )
12
- }
1
+ export * from './devtools'
You can’t perform that action at this time.
0 commit comments