Add WIP post-thread view

This commit is contained in:
Paul Frazee 2022-07-20 15:00:37 -05:00
parent 19c694bc60
commit c712cbbfe2
14 changed files with 534 additions and 25 deletions

View file

@ -1,20 +1,23 @@
import React, {useEffect} from 'react'
import {Text, View} from 'react-native'
import {View} from 'react-native'
import {Shell} from '../shell'
import {Feed} from '../com/Feed'
// import type {RootTabsScreenProps} from '../routes/types'
import {Feed} from '../com/feed/Feed'
import type {RootTabsScreenProps} from '../routes/types'
import {useStores} from '../../state'
export function Home(/*{navigation}: RootTabsScreenProps<'Home'>*/) {
export function Home({navigation}: RootTabsScreenProps<'Home'>) {
const store = useStores()
useEffect(() => {
console.log('Fetching home feed')
store.homeFeed.setup()
}, [store.homeFeed])
const onNavigateContent = (screen: string, props: Record<string, string>) => {
navigation.navigate(screen, props)
}
return (
<Shell>
<View>
<Feed feed={store.homeFeed} />
<Feed feed={store.homeFeed} onNavigateContent={onNavigateContent} />
</View>
</Shell>
)