fix(template): EmptyState takes children, not message #13
@@ -23,8 +23,12 @@ export default function Clans() {
|
||||
{loading && <Loading />}
|
||||
{error && <ErrorState error={error} />}
|
||||
|
||||
{/* `EmptyState` renders its CHILDREN and takes no other prop. Pass the
|
||||
sentence as `message=` and React drops it without a word: the panel
|
||||
renders as an empty box. module-rust shipped six of those for four
|
||||
phases, learned from this line when it said `message=`. */}
|
||||
{data && data.clans.length === 0 && (
|
||||
<EmptyState message="No clans have been reported yet." />
|
||||
<EmptyState>No clans have been reported yet.</EmptyState>
|
||||
)}
|
||||
|
||||
{data && data.clans.length > 0 && (
|
||||
|
||||
Reference in New Issue
Block a user