mirror of
https://github.com/bitsocialnet/5chan.git
synced 2026-08-03 07:41:04 +02:00
feat(catalog): add sorting option
This commit is contained in:
@@ -0,0 +1,13 @@
|
||||
import { create } from 'zustand';
|
||||
|
||||
interface SortingStore {
|
||||
sortType: 'active' | 'new';
|
||||
setSortType: (type: 'active' | 'new') => void;
|
||||
}
|
||||
|
||||
const useSortingStore = create<SortingStore>((set) => ({
|
||||
sortType: 'active',
|
||||
setSortType: (type) => set({ sortType: type }),
|
||||
}));
|
||||
|
||||
export default useSortingStore;
|
||||
Reference in New Issue
Block a user