-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathcomponent---src-pages-index-tsx-73e65b8f8a94562d2aa0.js.map
1 lines (1 loc) · 3.18 KB
/
component---src-pages-index-tsx-73e65b8f8a94562d2aa0.js.map
1
{"version":3,"sources":["webpack://gatsby-starter-blog/./src/pages/index.tsx"],"names":["data","location","siteTitle","site","siteMetadata","title","posts","allMarkdownRemark","edges","map","node","frontmatter","fields","slug","key","style","marginBottom","rhythm","Link","boxShadow","to","date","dangerouslySetInnerHTML","__html","description","excerpt"],"mappings":"4LAqEA,UAtCkB,SAAC,GAAyC,IAAvCA,EAAsC,EAAtCA,KAAMC,EAAgC,EAAhCA,SACnBC,EAAYF,EAAKG,KAAKC,aAAaC,MACnCC,EAAQN,EAAKO,kBAAkBC,MAErC,OACE,gBAAC,IAAD,CAAQP,SAAUA,EAAUI,MAAOH,GACjC,gBAAC,IAAD,CAAKG,MAAM,cAEVC,EAAMG,KAAI,YAAe,IAAZC,EAAW,EAAXA,KACNL,EAAQK,EAAKC,YAAYN,OAASK,EAAKE,OAAOC,KACpD,OACE,2BAASC,IAAKJ,EAAKE,OAAOC,MACxB,8BACE,sBACEE,MAAO,CACLC,cAAcC,QAAO,EAAI,KAG3B,gBAAC,EAAAC,KAAD,CAAMH,MAAO,CAAEI,UAAU,QAAWC,GAAIV,EAAKE,OAAOC,MACjDR,IAGL,6BAAQK,EAAKC,YAAYU,OAE3B,+BACE,qBACEC,wBAAyB,CACvBC,OAAQb,EAAKC,YAAYa,aAAed,EAAKe","file":"component---src-pages-index-tsx-73e65b8f8a94562d2aa0.js","sourcesContent":["// Gatsby supports TypeScript natively!\nimport React from \"react\"\nimport { PageProps, Link, graphql } from \"gatsby\"\n\nimport Layout from \"../components/layout\"\nimport SEO from \"../components/seo\"\nimport { rhythm } from \"../utils/typography\"\n\ntype Data = {\n site: {\n siteMetadata: {\n title: string\n }\n }\n allMarkdownRemark: {\n edges: {\n node: {\n excerpt: string\n frontmatter: {\n title: string\n date: string\n description: string\n }\n fields: {\n slug: string\n }\n }\n }[]\n }\n}\n\nconst BlogIndex = ({ data, location }: PageProps<Data>) => {\n const siteTitle = data.site.siteMetadata.title\n const posts = data.allMarkdownRemark.edges\n\n return (\n <Layout location={location} title={siteTitle}>\n <SEO title=\"All posts\" />\n \n {posts.map(({ node }) => {\n const title = node.frontmatter.title || node.fields.slug\n return (\n <article key={node.fields.slug}>\n <header>\n <h3\n style={{\n marginBottom: rhythm(1 / 4),\n }}\n >\n <Link style={{ boxShadow: `none` }} to={node.fields.slug}>\n {title}\n </Link>\n </h3>\n <small>{node.frontmatter.date}</small>\n </header>\n <section>\n <p\n dangerouslySetInnerHTML={{\n __html: node.frontmatter.description || node.excerpt,\n }}\n />\n </section>\n </article>\n )\n })}\n </Layout>\n )\n}\n\nexport default BlogIndex\n\nexport const pageQuery = graphql`\n query {\n site {\n siteMetadata {\n title\n }\n }\n allMarkdownRemark(\n sort: { fields: [frontmatter___date], order: DESC }\n filter: { fields: { draft: { eq: false } } }\n ) {\n edges {\n node {\n excerpt\n fields {\n slug\n }\n frontmatter {\n date(formatString: \"MMMM DD, YYYY\")\n title\n description\n }\n }\n }\n }\n }\n`\n"],"sourceRoot":""}