mirror of
https://github.com/jeffvli/feishin.git
synced 2026-05-10 04:30:25 +02:00
Begin normalizing list stores
This commit is contained in:
@@ -0,0 +1,16 @@
|
||||
import { createContext, useContext } from 'react';
|
||||
import { ListKey } from '/@/renderer/store';
|
||||
|
||||
interface SongListContextProps {
|
||||
id?: string;
|
||||
pageKey: ListKey;
|
||||
}
|
||||
|
||||
export const SongListContext = createContext<SongListContextProps>({
|
||||
pageKey: 'song',
|
||||
});
|
||||
|
||||
export const useSongListContext = () => {
|
||||
const ctxValue = useContext(SongListContext);
|
||||
return ctxValue;
|
||||
};
|
||||
Reference in New Issue
Block a user