Skip to content

Commit

Permalink
Load analytics ID in settings
Browse files Browse the repository at this point in the history
  • Loading branch information
kilemensi committed Sep 18, 2024
1 parent 7adcb30 commit ad7cfc9
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions apps/engineeringblog/lib/data/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -107,17 +107,23 @@ interface SecondaryNavigationProps extends NavigationProps {
copyright: string;
}

export type AnalyticsProps = {
analyticsId: string;
};

type SettingsProps = {
title: string;
primaryNavigation: PrimaryNavigationProps;
secondaryNavigation: SecondaryNavigationProps;
connect: ConnectProps;
analytics: AnalyticsProps;
};

async function readSettingsFile(filePath: string): Promise<SettingsProps> {
const { data } = await readMdFile(filePath);

return {
analytics: data.analytics,
connect: data.connect,
primaryNavigation: data.primaryNavigation,
secondaryNavigation: data.secondaryNavigation,
Expand Down

0 comments on commit ad7cfc9

Please sign in to comment.