-
Notifications
You must be signed in to change notification settings - Fork 2
/
gatsby-node.js
43 lines (43 loc) · 1.03 KB
/
gatsby-node.js
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
exports.createSchemaCustomization = ({ actions }) => {
const { createTypes } = actions;
const typeDefs = `
type MarkdownRemark implements Node {
frontmatter: Frontmatter
}
type Contact {
value: String!
url: String!
icon: String!
}
type Address {
recipient: String
date: Date
datelocale: String
business: String
address: [String]
}
type Entry {
title: String!
content: String!
}
type Frontmatter implements Node @dontInfer{
firstname: String
lastname: String
titles: [String!]
address: Address
contact: [Contact!]
title: String!
subtitle: String!
location: String
startDate: Date @dateformat(formatString: "") # Somehow this is needed for dates to be parsed properly
endDate: Date @dateformat(formatString: "")
subject: String
ps: [String]
entries: [Entry!]
items: [String]
dateFormat: String
singleDate: Boolean
}
`;
createTypes(typeDefs);
};