import ListCapsule from '../data/Capsule.json';

export interface CapsuleInfo {
    id: number;
    title: string;
    content: string;
    photo: string;
}

export const getCapsules = () => ListCapsule;

export const getCapsule = (id: number) => ListCapsule.find(c => c.id === id);