import { useQuery } from 'react-orbit';
interface RecordIdentity {
type: string
id: string|number
}
interface RecordsIdentity {
type: string
}
export default function Customers() {
let {
data: customers = [],
isLoading,
error,
queryStore
} = useQuery(RecordIdentity|RecordsIdentity, equalityFn?);
useEffect(() => {
queryStore(t => t.findRecords('customer'));
}, [queryStore]);
return (
<>
{customers.map((customer) => <CustomerListItem customer={customer}>)}
</>
);
}
-
Notifications
You must be signed in to change notification settings - Fork 0
selvagsz/react-orbit-example
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Folders and files
Name | Name | Last commit message | Last commit date | |
---|---|---|---|---|
Repository files navigation
About
A demo app on react + orbitjs
Resources
Stars
Watchers
Forks
Releases
No releases published
Packages 0
No packages published