import { SearchLayout } from '@/components/layout' import { getGetServerSideProps } from '@/api/ssrApollo' import { useRouter } from 'next/router' import { SUB_SEARCH } from '@/fragments/subs' import Items from '@/components/items' import styles from '@/styles/search.module.css' export const getServerSideProps = getGetServerSideProps({ query: SUB_SEARCH, notFound: (data, vars) => vars.sub && !data.sub }) export default function Index ({ ssrData }) { const router = useRouter() const variables = { ...router.query, includeComments: true } const sub = ssrData?.sub?.name || variables.sub return ( {variables.q ? data.search} variables={variables} noMoreText='NO MORE' /> : (
filters
  • @nym - limit to results authored by nym
  • ~territory - limit to results from territory
  • url:stacker​.news - limit to link posts from a specific url
  • "exact phrase" - limit to results that contain an exact phrase
)}
) }