mirror of
https://github.com/ForFarmTeam/ForFarm.git
synced 2025-12-19 05:54:08 +01:00
11 lines
265 B
TypeScript
11 lines
265 B
TypeScript
import axiosInstance from "./config";
|
|
import type { Plant } from "@/types";
|
|
|
|
export interface PlantResponse {
|
|
plants: Plant[];
|
|
}
|
|
|
|
export function getPlants(): Promise<PlantResponse> {
|
|
return axiosInstance.get<PlantResponse>("/plant").then((res) => res.data);
|
|
}
|