feat: add Class interface import to classes service for type safety
This commit is contained in:
parent
5bfc969f6a
commit
1c897648f7
@ -1,4 +1,5 @@
|
|||||||
import { API_URLS } from "../constants/apiUrl.constant";
|
import { API_URLS } from "../constants/apiUrl.constant";
|
||||||
|
import { Class } from "../interface/class";
|
||||||
import { axiosInstance } from "../lib/axios";
|
import { axiosInstance } from "../lib/axios";
|
||||||
|
|
||||||
const getAll = () => axiosInstance.get<Class[]>(API_URLS.class.all);
|
const getAll = () => axiosInstance.get<Class[]>(API_URLS.class.all);
|
||||||
|
@ -1,5 +1,6 @@
|
|||||||
import { create } from "zustand";
|
import { create } from "zustand";
|
||||||
import { classesService } from "../services/classes.service";
|
import { classesService } from "../services/classes.service";
|
||||||
|
import { Class } from "../interface/class";
|
||||||
|
|
||||||
type ClassStoreState = {
|
type ClassStoreState = {
|
||||||
classes: Class[];
|
classes: Class[];
|
||||||
|
Loading…
Reference in New Issue
Block a user