User
Type '{ rep: Replicache<Mutators> | null; }' is not assignable to type 'IntrinsicAttributes & Replicache<Mutators>'.
Property 'rep' does not exist on type 'IntrinsicAttributes & Replicache<Mutators>'.ts(2322)
'use client'
import Lists from '@components/Lists'
import TodoApp from '@components/TodoApp'
import { getRowVersioningReplicache } from '@replicache/constructor'
const App = () => {
const rep = getRowVersioningReplicache()
return (
<div>
<Lists rep={rep} />
<TodoApp rep={rep} />
</div>
)
}
export default App
'use client'
import { css } from '@styled-system/css'
import type { Mutators } from '@replicache/mutators'
import type { Replicache } from 'replicache'
import DisplayLists from './DisplayLists'
const Lists = (rep: Replicache<Mutators> | null) => (
<div
className={css({
display: 'flex',
flexDir: 'column',
width: '150px',
fontSize: '125%',
paddingTop: '155px',
})}
id="navigation"
<DisplayLists rep={rep} />
</div>
)
export default Lists
'use client'
import Link from 'next/link'
import { useSubscribe } from 'replicache-react'
import { type Mutators, listLists } from '@replicache/mutators'
import type { Replicache } from 'replicache'
const DisplayLists = (rep: Replicache<Mutators> | null) => {
const lists = useSubscribe(rep, listLists, [], [rep])
return (
<div>
{lists.map((list) => (
<Link key={list.id} href={/list/${list.id}}>
{list.name}
</Link>
))}
</div>
)
}
export default DisplayLists