mirror of
https://github.com/colanode/colanode.git
synced 2026-07-09 20:08:46 +02:00
Mobile duplicated useLiveQuery, useQuery, useMutation, and buildQueryClient from packages/ui with the only difference being the executor mechanism (appService.mediator vs window.colanode). This consolidates them by: - Adding a DOM-free core-api module to packages/ui with getColanode() and getEventBus() helpers that access globalThis, avoiding Window/DOM types - Updating shared hooks and buildQueryClient to use these helpers instead of window.colanode/window.eventBus directly - Installing a globalThis.colanode bridge in mobile's _layout.tsx that delegates to appService.mediator (matching the web/desktop pattern) - Migrating all 41 mobile files to import hooks from @colanode/ui - Deleting 4 duplicate mobile files (3 hooks + query-client) - Adding Metro resolver override to force react/react-native resolution from the mobile app's node_modules (packages/ui ships a separate web-only React 19.2.4 that conflicts with mobile's RN-compatible 19.1.0) Also standardizes useQuery to use buildQueryKey instead of inline sha256. Co-authored-by: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
26 lines
733 B
JSON
26 lines
733 B
JSON
{
|
|
"compilerOptions": {
|
|
"strict": true,
|
|
"target": "ES2020",
|
|
"lib": ["ES2020"],
|
|
"module": "esnext",
|
|
"moduleResolution": "bundler",
|
|
"esModuleInterop": true,
|
|
"allowSyntheticDefaultImports": true,
|
|
"jsx": "react-native",
|
|
"skipLibCheck": true,
|
|
"resolveJsonModule": true,
|
|
"paths": {
|
|
"@assets": ["./assets"],
|
|
"@colanode/mobile/*": ["./src/*"],
|
|
"@colanode/ui/*": ["../../packages/ui/src/*"],
|
|
"@colanode/core/*": ["../../packages/core/src/*"],
|
|
"@colanode/crdt/*": ["../../packages/crdt/src/*"],
|
|
"@colanode/client/*": ["../../packages/client/src/*"]
|
|
}
|
|
},
|
|
"exclude": ["node_modules", "webviews"],
|
|
"extends": "expo/tsconfig.base",
|
|
"include": ["**/*"]
|
|
}
|