Structure de données jeu client

This commit is contained in:
2024-12-11 17:26:36 +01:00
parent d1adba04da
commit 7aa9dde5a9
14 changed files with 238 additions and 28 deletions

View File

@ -0,0 +1,27 @@
import { createSlice } from '@reduxjs/toolkit'
export interface Challenge {
id: number
title: string,
description: string,
reward: number,
}
export interface ChallengesState {
challenges: Challenge[]
}
const initialState: ChallengesState = {
challenges: []
}
export const challengesSlice = createSlice({
name: 'challenges',
initialState: initialState,
reducers: {
},
})
export const { } = challengesSlice.actions
export default challengesSlice.reducer