Skip to content

tosaken1116/Tyranno_front

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Hack'z Hackathon Tyranno Cup

zustand

Store呼び出し

import { shallow } from 'zustand/shallow';

import useStore from '@/src/store/store';
// 複数同時取得
const slideState = useStore(
  (state) => ({
    pageNumber: state.pageNumber,
    movePrevPage: state.movePrevPage,
    moveNextPage: state.moveNextPage,
    moveToPage: state.moveToPage,
    setPageTotalNumber: state.setPageTotalNumber,
  }),
  shallow
);
// 一つ取得
const users = useStore((state) => state.users);