@vanyamate/sec-react
v0.0.6
Published
Support for react
Downloads
42
Readme
SEC React
Support for sec
npm i @vanyamate/sec-react
// /model/todo/todo.model.ts
import { store } from '@vanyamate/sec';
export const todoLoading = store(false);
import { useStore } from '@vanyamate/sec-react';
// any react component
const loading = useStore(todoLoading);
if (loading) {
return <Loader/>;
}
return (
<Component/>
);