feat: add history
This commit is contained in:
10
composables/store/history.ts
Normal file
10
composables/store/history.ts
Normal file
@@ -0,0 +1,10 @@
|
||||
import { useStorage } from '@vueuse/core'
|
||||
import { namespace } from '~/constants'
|
||||
import type { RecipeItem } from '~/types'
|
||||
|
||||
export interface RecipeHistoryItem {
|
||||
recipe: RecipeItem
|
||||
time: number
|
||||
}
|
||||
|
||||
export const recipeHistories = useStorage<RecipeHistoryItem[]>(`${namespace}:history`, [])
|
||||
Reference in New Issue
Block a user