fix: fix link
This commit is contained in:
parent
b3acce6854
commit
5df4d34780
1 changed files with 3 additions and 3 deletions
|
|
@ -1,5 +1,5 @@
|
||||||
import * as React from "react"
|
import * as React from "react"
|
||||||
import { graphql, PageProps } from "gatsby"
|
import { graphql, Link, PageProps } from "gatsby"
|
||||||
import Layout from "../../components/organisms/Layout"
|
import Layout from "../../components/organisms/Layout"
|
||||||
|
|
||||||
const Blog = ({ data: { allMdx } }: PageProps<Queries.BlogQuery>) => {
|
const Blog = ({ data: { allMdx } }: PageProps<Queries.BlogQuery>) => {
|
||||||
|
|
@ -7,9 +7,9 @@ const Blog = ({ data: { allMdx } }: PageProps<Queries.BlogQuery>) => {
|
||||||
return (
|
return (
|
||||||
<Layout pageTitle="Blog">
|
<Layout pageTitle="Blog">
|
||||||
{allMdx.edges.map(({ node: post }) => (
|
{allMdx.edges.map(({ node: post }) => (
|
||||||
<a href={`//${location.host}/blog/${post.slug}`}>
|
<Link to={`/blog/${post.slug}`}>
|
||||||
<h2>{post.frontmatter?.title}</h2>
|
<h2>{post.frontmatter?.title}</h2>
|
||||||
</a>
|
</Link>
|
||||||
))}
|
))}
|
||||||
</Layout>
|
</Layout>
|
||||||
)
|
)
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue