Working search
This commit is contained in:
parent
271cf1f407
commit
2a572e8bc4
15 changed files with 217 additions and 39 deletions
|
|
@ -15,6 +15,8 @@ const ServerSearch = ({ searchTerm, server }: ServerSearchProps) => {
|
|||
useEffect(() => {
|
||||
search(searchTerm, server.id).then(results => {
|
||||
setSearchResults(results);
|
||||
}).catch(err => {
|
||||
alert(err);
|
||||
})
|
||||
}, [searchTerm]);
|
||||
|
||||
|
|
@ -22,7 +24,7 @@ const ServerSearch = ({ searchTerm, server }: ServerSearchProps) => {
|
|||
<Table striped bordered >
|
||||
<thead>
|
||||
<tr>
|
||||
<th>{server.name}</th>
|
||||
<th>{server.owner}'s server</th>
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue