mirror of
https://github.com/bitsocialnet/5chan.git
synced 2026-08-03 07:41:04 +02:00
feat(board): show error in feed near loading string
This commit is contained in:
@@ -49,7 +49,7 @@ const Board = () => {
|
||||
setResetFunction(reset);
|
||||
}, [reset, setResetFunction]);
|
||||
|
||||
const subplebbit = useSubplebbit({ subplebbitAddress });
|
||||
const { subplebbit, error } = useSubplebbit({ subplebbitAddress });
|
||||
const { createdAt, description, rules, shortAddress, state, suggested } = subplebbit || {};
|
||||
const title = isInAllView ? t('all') : isInSubscriptionsView ? t('subscriptions') : subplebbit?.title;
|
||||
|
||||
@@ -65,6 +65,12 @@ const Board = () => {
|
||||
) : (
|
||||
<LoadingEllipsis string={loadingStateString} />
|
||||
)}
|
||||
{error && (
|
||||
<div style={{ color: 'red' }}>
|
||||
<br />
|
||||
{error.message}
|
||||
</div>
|
||||
)}
|
||||
</div>
|
||||
);
|
||||
|
||||
|
||||
Reference in New Issue
Block a user