This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/** | |
* Layout component that queries for data | |
* with Gatsby's useStaticQuery component | |
* | |
* See: https://www.gatsbyjs.org/docs/use-static-query/ | |
*/ | |
import React from 'react'; | |
import PropTypes from 'prop-types'; | |
import { useStaticQuery, graphql } from 'gatsby'; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/** | |
* SEO component that queries for data with | |
* Gatsby's useStaticQuery React hook | |
* | |
* See: https://www.gatsbyjs.org/docs/use-static-query/ | |
*/ | |
import React from 'react'; | |
import PropTypes from 'prop-types'; | |
import Helmet from 'react-helmet'; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import React from 'react'; | |
import { useStaticQuery, graphql } from 'gatsby'; | |
import Img from 'gatsby-image'; | |
/* | |
* This component is built using `gatsby-image` to automatically serve optimized | |
* images with lazy loading and reduced file sizes. The image is loaded using a | |
* `useStaticQuery`, which allows us to load the image from directly within this | |
* component, rather than having to pass the image data down from pages. | |
* |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import { Link } from 'gatsby'; | |
import PropTypes from 'prop-types'; | |
import React from 'react'; | |
const Header = ({ siteTitle }) => ( | |
<header | |
style={{ | |
background: 'rebeccapurple', | |
marginBottom: '1.45rem', | |
}} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import React from 'react'; | |
import { Link } from 'gatsby'; | |
import Layout from '../components/layout'; | |
import SEO from '../components/seo'; | |
const SecondPage = () => ( | |
<Layout> | |
<SEO title="Page two" /> | |
<h1>Hi from the second page</h1> |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import React from 'react'; | |
import Layout from '../components/layout'; | |
import SEO from '../components/seo'; | |
const NotFoundPage = () => ( | |
<Layout> | |
<SEO title="404: Not found" /> | |
<h1>NOT FOUND</h1> | |
<p>You just hit a route that doesn't exist... the sadness.</p> |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import React from 'react'; | |
import { Link } from 'gatsby'; | |
import Layout from '../components/layout'; | |
import Image from '../components/image'; | |
import SEO from '../components/seo'; | |
const IndexPage = () => ( | |
<Layout> | |
<SEO title="Home" /> |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
extends: stylelint-config-standard | |
plugins: | |
- stylelint-selector-bem-pattern | |
- stylelint-scss | |
- stylelint-order | |
rules: | |
# Override stylelint-config-standard - we only use CSS comments for annotations that don't warrant an empty line | |
comment-empty-line-before: null | |
# Follow best practices | |
font-family-name-quotes: always-where-recommended |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Show hidden characters
{ | |
"extends": "airbnb", | |
"parser": "babel-eslint", | |
"rules": { | |
"jsx-a11y/anchor-is-valid": ["error", { | |
"components": ["Link"], | |
"specialLink": ["hrefLeft", "hrefRight", "to"], | |
"aspects": ["noHref", "invalidHref", "preferButton"] | |
}], | |
"react/jsx-filename-extension": [1, { "extensions": [".jsx"] }], |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{ | |
"extends": "airbnb", | |
"parser": "babel-eslint", | |
"rules": { | |
"jsx-a11y/anchor-is-valid": ["error", { | |
"components": ["Link"], | |
"specialLink": ["hrefLeft", "hrefRight", "to"], | |
"aspects": ["noHref", "invalidHref", "preferButton"] | |
}], | |
"react/jsx-filename-extension": [1, { "extensions": [".jsx"] }], |