webapp/src/components/types.ts
2022-11-12 21:59:29 +03:00

19 lines
463 B
TypeScript

// in a separate file to avoid circular dependencies
import type { Author, Chat, Shout, Topic } from '../graphql/types.gen'
// all the things (she said) that could be passed from the server
export type PageProps = {
randomTopics?: Topic[]
article?: Shout
shouts?: Shout[]
author?: Author
allAuthors?: Author[]
topic?: Topic
allTopics?: Topic[]
searchQuery?: string
layout?: string
// other types?
searchResults?: Shout[]
chats?: Chat[]
}