Skip to content

Commit

Permalink
clean up loading
Browse files Browse the repository at this point in the history
  • Loading branch information
MrKevinOConnell committed Aug 27, 2024
1 parent 719b973 commit 1f89d25
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions src/components/CastSearch.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -122,8 +122,9 @@ const CastSearch = ({ query }: { query: string }) => {
</form>

<div className="space-y-4 p-4 w-full max-w-4xl">
{loading && casts.length === 0 ? <p>Loading....</p> : null}
{casts && casts.length ? (
{loading && casts.length === 0 ? (
<p className="text-center text-white font-jetbrains">Loading....</p>
) : casts && casts.length ? (
casts.map((cast, index) => (
<NeynarCastCard
key={`${cast.hash}-${index}`}
Expand Down

0 comments on commit 1f89d25

Please sign in to comment.