forked from UKSOURCE/ipv6
13 lines
265 B
TypeScript
13 lines
265 B
TypeScript
import axiosInstance from "../lib/axios";
|
|
|
|
export const fetchContentPageData = async <T>(
|
|
endpoint: string,
|
|
): Promise<T | null> => {
|
|
try {
|
|
const response = await axiosInstance.get<T>(endpoint);
|
|
return response.data;
|
|
} catch {
|
|
return null;
|
|
}
|
|
};
|