Adds I-prefix to all interfaces
This commit is contained in:
parent
80aaab46f2
commit
8ec5f52872
44 changed files with 1731 additions and 1949 deletions
|
|
@ -1,4 +1,4 @@
|
|||
import { CalendarEvent } from '../types/CalendarTypes';
|
||||
import { ICalendarEvent } from '../types/CalendarTypes';
|
||||
import { IEventRepository } from './IEventRepository';
|
||||
|
||||
interface RawEventData {
|
||||
|
|
@ -23,7 +23,7 @@ interface RawEventData {
|
|||
export class MockEventRepository implements IEventRepository {
|
||||
private readonly dataUrl = 'data/mock-events.json';
|
||||
|
||||
public async loadEvents(): Promise<CalendarEvent[]> {
|
||||
public async loadEvents(): Promise<ICalendarEvent[]> {
|
||||
try {
|
||||
const response = await fetch(this.dataUrl);
|
||||
|
||||
|
|
@ -40,8 +40,8 @@ export class MockEventRepository implements IEventRepository {
|
|||
}
|
||||
}
|
||||
|
||||
private processCalendarData(data: RawEventData[]): CalendarEvent[] {
|
||||
return data.map((event): CalendarEvent => ({
|
||||
private processCalendarData(data: RawEventData[]): ICalendarEvent[] {
|
||||
return data.map((event): ICalendarEvent => ({
|
||||
...event,
|
||||
start: new Date(event.start),
|
||||
end: new Date(event.end),
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue