|
11 | 11 | "url": "git+https://github.com/react-restart/ui.git" |
12 | 12 | }, |
13 | 13 | "license": "MIT", |
14 | | - "main": "lib/cjs/index.js", |
15 | | - "module": "lib/esm/index.js", |
16 | | - "types": "lib/esm/index.d.ts", |
| 14 | + "main": "cjs/index.js", |
| 15 | + "module": "lib/index.js", |
| 16 | + "types": "lib/index.d.ts", |
17 | 17 | "exports": { |
| 18 | + "./package.json": "./package.json", |
18 | 19 | ".": { |
19 | | - "types": "./esm/index.d.ts", |
20 | | - "node": "./cjs/index.js", |
21 | | - "import": "./esm/index.js", |
22 | | - "require": "./cjs/index.js" |
| 20 | + "node": { |
| 21 | + "types": "./cjs/index.d.ts", |
| 22 | + "default": "./cjs/index.js" |
| 23 | + }, |
| 24 | + "require": { |
| 25 | + "types": "./cjs/index.d.ts", |
| 26 | + "default": "./cjs/index.js" |
| 27 | + }, |
| 28 | + "import": { |
| 29 | + "types": "./lib/index.d.ts", |
| 30 | + "default": "./lib/index.js" |
| 31 | + } |
23 | 32 | }, |
24 | 33 | "./*": { |
25 | | - "types": "./esm/*.d.ts", |
26 | | - "node": "./cjs/*.js", |
27 | | - "import": "./esm/*.js", |
28 | | - "require": "./cjs/*.js" |
| 34 | + "node": { |
| 35 | + "types": "./cjs/*.d.ts", |
| 36 | + "default": "./cjs/*.js" |
| 37 | + }, |
| 38 | + "require": { |
| 39 | + "types": "./cjs/*.d.ts", |
| 40 | + "default": "./cjs/*.js" |
| 41 | + }, |
| 42 | + "import": { |
| 43 | + "types": "./lib/*.d.ts", |
| 44 | + "default": "./lib/*.js" |
| 45 | + } |
29 | 46 | } |
30 | 47 | }, |
31 | 48 | "sideEffects": false, |
32 | 49 | "files": [ |
33 | | - "lib" |
| 50 | + "lib", |
| 51 | + "cjs" |
34 | 52 | ], |
35 | 53 | "gitHooks": { |
36 | 54 | "pre-commit": "lint-staged" |
|
48 | 66 | ], |
49 | 67 | "scripts": { |
50 | 68 | "bootstrap": "yarn --network-timeout 100000 && yarn --cwd www --network-timeout 100000", |
51 | | - "build": "rimraf lib && 4c build src && yarn build:popper && yarn build:pick", |
| 69 | + "build": "rimraf lib && yarn build:esm && yarn build:cjs && yarn build:popper", |
| 70 | + "build:esm": "babel src --out-dir lib --delete-dir-on-start --extensions '.ts,.tsx' --ignore='**/*.d.ts' && yarn build:esm:types", |
| 71 | + "build:cjs": "babel src --out-dir cjs --env-name cjs --delete-dir-on-start --extensions '.ts,.tsx' --ignore='**/*.d.ts' && yarn build:cjs:types && echo '{\"type\": \"commonjs\"}' > cjs/package.json", |
| 72 | + "build:esm:types": "tsc -p . --emitDeclarationOnly --declaration --outDir lib", |
| 73 | + "build:cjs:types": "tsc -p . --emitDeclarationOnly --declaration --outDir cjs", |
52 | 74 | "build:pick": "cherry-pick --cwd=lib --input-dir=../src --cjs-dir=cjs --esm-dir=esm", |
53 | | - "build:popper": "rollup src/popper.ts --file lib/cjs/popper.js --format cjs --name popper --plugin @rollup/plugin-node-resolve", |
| 75 | + "build:popper": "rollup src/popper.ts --file cjs/popper.js --format cjs --name popper --plugin @rollup/plugin-node-resolve && rollup src/popper.ts --file lib/popper.js --format esm --name popper --plugin @rollup/plugin-node-resolve", |
54 | 76 | "deploy-docs": "yarn --cwd www deploy", |
55 | | - "lint": "eslint www/*.js www/src src test *.ts --ext .js,.ts,.tsx", |
| 77 | + "lint": "eslint src test", |
56 | 78 | "prepublishOnly": "yarn build", |
57 | 79 | "release": "rollout", |
58 | 80 | "start": "yarn --cwd www start", |
|
61 | 83 | "testonly": "vitest --run" |
62 | 84 | }, |
63 | 85 | "lint-staged": { |
64 | | - "*.js,*.tsx": "eslint --fix --ext .js,.ts,.tsx" |
| 86 | + "*.js,*.tsx": "eslint --fix" |
65 | 87 | }, |
66 | 88 | "prettier": { |
67 | 89 | "singleQuote": true, |
|
75 | 97 | "conventionalCommits": true |
76 | 98 | }, |
77 | 99 | "dependencies": { |
| 100 | + "@babel/eslint-parser": "^7.25.9", |
78 | 101 | "@babel/runtime": "^7.26.0", |
79 | 102 | "@popperjs/core": "^2.11.8", |
80 | 103 | "@react-aria/ssr": "^3.5.0", |
81 | | - "@restart/hooks": "^0.5.0", |
| 104 | + "@restart/hooks": "^0.6.2", |
82 | 105 | "@types/warning": "^3.0.3", |
83 | 106 | "dequal": "^2.0.3", |
84 | 107 | "dom-helpers": "^5.2.0", |
85 | | - "uncontrollable": "^8.0.4", |
| 108 | + "uncontrollable": "^9.0.0", |
86 | 109 | "warning": "^4.0.3" |
87 | 110 | }, |
88 | 111 | "peerDependencies": { |
|
93 | 116 | "@4c/cli": "^4.0.4", |
94 | 117 | "@4c/rollout": "^4.0.2", |
95 | 118 | "@4c/tsconfig": "^0.4.1", |
96 | | - "@babel/cli": "^7.20.7", |
97 | | - "@babel/core": "^7.20.12", |
98 | | - "@babel/preset-react": "^7.18.6", |
99 | | - "@babel/preset-typescript": "^7.18.6", |
| 119 | + "@babel/cli": "^7.26.4", |
| 120 | + "@babel/core": "^7.26.0", |
| 121 | + "@babel/preset-react": "^7.26.3", |
| 122 | + "@babel/preset-typescript": "^7.26.0", |
| 123 | + "@eslint/js": "^9.17.0", |
100 | 124 | "@react-bootstrap/eslint-config": "^2.0.0", |
101 | 125 | "@rollup/plugin-node-resolve": "^15.2.3", |
102 | 126 | "@testing-library/dom": "^10.3.1", |
|
106 | 130 | "@types/react": "^18.3.3", |
107 | 131 | "@types/react-dom": "^18.3.0", |
108 | 132 | "@types/react-transition-group": "^4.4.4", |
109 | | - "@typescript-eslint/eslint-plugin": "^4.33.0", |
110 | | - "@typescript-eslint/parser": "^4.33.0", |
| 133 | + "@typescript-eslint/eslint-plugin": "^8.19.1", |
| 134 | + "@typescript-eslint/parser": "^8.19.1", |
111 | 135 | "@vitejs/plugin-react": "^4.3.2", |
112 | 136 | "@vitest/browser": "^2.1.3", |
113 | 137 | "@vitest/coverage-istanbul": "2.1.3", |
|
116 | 140 | "babel-preset-env-modules": "^1.0.1", |
117 | 141 | "cherry-pick": "^0.5.0", |
118 | 142 | "cross-env": "^7.0.3", |
119 | | - "eslint": "^7.24.0", |
120 | | - "eslint-config-4catalyzer-typescript": "^3.2.1", |
121 | | - "eslint-config-prettier": "^8.5.0", |
122 | | - "eslint-plugin-import": "^2.26.0", |
123 | | - "eslint-plugin-jsx-a11y": "^6.5.1", |
124 | | - "eslint-plugin-prettier": "^3.4.1", |
125 | | - "eslint-plugin-react": "^7.30.0", |
126 | | - "eslint-plugin-react-hooks": "^4.6.0", |
| 143 | + "eslint": "^9.17.0", |
| 144 | + "eslint-config-4catalyzer-typescript": "^3.3.0", |
| 145 | + "eslint-config-prettier": "^9.1.0", |
| 146 | + "eslint-plugin-import": "^2.31.0", |
| 147 | + "eslint-plugin-jsx-a11y": "^6.10.2", |
| 148 | + "eslint-plugin-prettier": "^5.2.1", |
| 149 | + "eslint-plugin-react": "^7.37.3", |
| 150 | + "eslint-plugin-react-hooks": "^5.1.0", |
127 | 151 | "gh-pages": "^3.1.0", |
| 152 | + "globals": "^15.14.0", |
128 | 153 | "hookem": "^1.0.9", |
129 | 154 | "lint-staged": "^10.5.4", |
130 | 155 | "playwright": "^1.48.0", |
131 | | - "prettier": "^2.7.1", |
| 156 | + "prettier": "^3.4.2", |
132 | 157 | "react": "^18.3.1", |
133 | 158 | "react-dom": "^18.3.1", |
134 | 159 | "react-transition-group": "^4.4.1", |
135 | 160 | "rimraf": "^3.0.2", |
136 | 161 | "rollup": "^4.18.1", |
137 | | - "typescript": "^4.7.4", |
| 162 | + "typescript": "^5.7.3", |
| 163 | + "typescript-eslint": "^8.19.1", |
138 | 164 | "vitest": "^2.1.3" |
139 | 165 | }, |
140 | 166 | "bugs": { |
|
0 commit comments