Skip to content

Commit

Permalink
Fix typescript error.
Browse files Browse the repository at this point in the history
  • Loading branch information
mayank1513 committed Feb 25, 2024
1 parent b238a2e commit 209a24b
Show file tree
Hide file tree
Showing 6 changed files with 34 additions and 34 deletions.
10 changes: 5 additions & 5 deletions examples/nextjs/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -10,18 +10,18 @@
"postinstall": "next telemetry disable"
},
"dependencies": {
"@mayank1513/fork-me": "latest",
"r18gs": "workspace:*",
"@mayank1513/fork-me": "^2.0.1",
"next": "^14.1.0",
"nextjs-themes": "^2.1.1",
"nextjs-themes": "^2.1.2",
"r18gs": "workspace:*",
"react": "^18.2.0",
"react-dom": "^18.2.0",
"shared-ui": "workspace:*"
},
"devDependencies": {
"@next/eslint-plugin-next": "^14.1.0",
"@types/node": "^20.11.19",
"@types/react": "^18.2.56",
"@types/node": "^20.11.20",
"@types/react": "^18.2.58",
"@types/react-dom": "^18.2.19",
"eslint-config-custom": "workspace:*",
"tsconfig": "workspace:*",
Expand Down
22 changes: 11 additions & 11 deletions examples/remix/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -11,24 +11,24 @@
"typecheck": "tsc"
},
"dependencies": {
"@mayank1513/fork-me": "latest",
"r18gs": "workspace:*",
"@remix-run/css-bundle": "^2.6.0",
"@remix-run/node": "^2.6.0",
"@remix-run/react": "^2.6.0",
"@remix-run/serve": "^2.6.0",
"@mayank1513/fork-me": "^2.0.1",
"@remix-run/css-bundle": "^2.7.2",
"@remix-run/node": "^2.7.2",
"@remix-run/react": "^2.7.2",
"@remix-run/serve": "^2.7.2",
"isbot": "5.1.0",
"nextjs-themes": "^2.1.1",
"nextjs-themes": "^2.1.2",
"r18gs": "workspace:*",
"react": "^18.2.0",
"react-dom": "^18.2.0",
"shared-ui": "workspace:*"
},
"devDependencies": {
"@remix-run/dev": "^2.6.0",
"@remix-run/eslint-config": "^2.6.0",
"@types/react": "^18.2.56",
"@remix-run/dev": "^2.7.2",
"@remix-run/eslint-config": "^2.7.2",
"@types/react": "^18.2.58",
"@types/react-dom": "^18.2.19",
"eslint": "^8.56.0",
"eslint": "^8.57.0",
"typescript": "^5.3.3"
},
"engines": {
Expand Down
14 changes: 7 additions & 7 deletions examples/vite/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -10,23 +10,23 @@
"preview": "vite preview"
},
"dependencies": {
"@mayank1513/fork-me": "latest",
"@mayank1513/fork-me": "^2.0.1",
"nextjs-themes": "^2.1.2",
"r18gs": "workspace:*",
"nextjs-themes": "^2.1.1",
"react": "^18.2.0",
"react-dom": "^18.2.0",
"shared-ui": "workspace:*"
},
"devDependencies": {
"@types/react": "^18.2.56",
"@types/react": "^18.2.58",
"@types/react-dom": "^18.2.19",
"@typescript-eslint/eslint-plugin": "^7.0.1",
"@typescript-eslint/parser": "^7.0.1",
"@typescript-eslint/eslint-plugin": "^7.0.2",
"@typescript-eslint/parser": "^7.0.2",
"@vitejs/plugin-react-swc": "^3.6.0",
"eslint": "^8.56.0",
"eslint": "^8.57.0",
"eslint-plugin-react-hooks": "^4.6.0",
"eslint-plugin-react-refresh": "^0.4.5",
"typescript": "^5.3.3",
"vite": "^5.1.3"
"vite": "^5.1.4"
}
}
8 changes: 4 additions & 4 deletions lib/r18gs/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -26,11 +26,11 @@
"devDependencies": {
"@testing-library/react": "^14.2.1",
"@turbo/gen": "^1.12.4",
"@types/node": "^20.11.19",
"@types/react": "^18.2.56",
"@types/node": "^20.11.20",
"@types/react": "^18.2.58",
"@types/react-dom": "^18.2.19",
"@vitejs/plugin-react": "^4.2.1",
"@vitest/coverage-v8": "^1.3.0",
"@vitest/coverage-v8": "^1.3.1",
"eslint-config-custom": "workspace:*",
"jsdom": "^24.0.0",
"octokit": "^3.1.2",
Expand All @@ -40,7 +40,7 @@
"typedoc": "^0.25.8",
"typescript": "^5.3.3",
"vite-tsconfig-paths": "^4.3.1",
"vitest": "^1.3.0"
"vitest": "^1.3.1"
},
"peerDependencies": {
"@types/react": "16.8 - 18",
Expand Down
2 changes: 1 addition & 1 deletion lib/r18gs/src/use-rgs.ts
Original file line number Diff line number Diff line change
Expand Up @@ -51,6 +51,6 @@ export default function useRGS<T>(key: string, value?: T): [T, (val: SetterArgTy
// eslint-disable-next-line @typescript-eslint/no-unsafe-member-access -- temp fix
const getSnapshot = () => (globalThis.rgs[key]?.value ?? value) as T;

const val = useSyncExternalStore<T>(subscribe, getSnapshot, () => value);
const val = useSyncExternalStore<T>(subscribe, getSnapshot, () => value as T);
return [val, setRGState];
}
12 changes: 6 additions & 6 deletions packages/shared-ui/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -10,19 +10,19 @@
"lint": "eslint ."
},
"devDependencies": {
"@mayank1513/fork-me": "latest",
"r18gs": "workspace:*",
"@types/node": "^20.11.19",
"@types/react": "^18.2.56",
"@mayank1513/fork-me": "^2.0.1",
"@types/node": "^20.11.20",
"@types/react": "^18.2.58",
"@types/react-dom": "^18.2.19",
"eslint-config-custom": "workspace:*",
"next": "^14.1.0",
"nextjs-themes": "^2.1.1",
"nextjs-themes": "^2.1.2",
"r18gs": "workspace:*",
"react": "^18.2.0",
"tsconfig": "workspace:*",
"typescript": "5.3.3"
},
"dependencies": {
"eslint": "^8.56.0"
"eslint": "^8.57.0"
}
}

0 comments on commit 209a24b

Please sign in to comment.