Add API Routes starter

This commit is contained in:
Shu Uesugi
2020-04-02 20:21:12 -07:00
parent 57f7967936
commit 2a4e1b13e6
22 changed files with 428 additions and 42 deletions

View File

@@ -1,30 +1 @@
This is a [Next.js](https://nextjs.org/) project bootstrapped with [`create-next-app`](https://github.com/zeit/next.js/tree/canary/packages/create-next-app).
## Getting Started
First, run the development server:
```bash
npm run dev
# or
yarn dev
```
Open [http://localhost:3000](http://localhost:3000) with your browser to see the result.
You can start editing the page by modifying `pages/index.js`. The page auto-updates as you edit the file.
## Learn More
To learn more about Next.js, take a look at the following resources:
- [Next.js Documentation](https://nextjs.org/docs) - learn about Next.js features and API.
- [Learn Next.js](https://nextjs.org/learn) - an interactive Next.js tutorial.
You can check out [the Next.js GitHub repository](https://github.com/zeit/next.js/) - your feedback and contributions are welcome!
## Deploy on ZEIT Now
The easiest way to deploy your Next.js app is to use the [ZEIT Now Platform](https://zeit.co/import?utm_medium=default-template&filter=next.js&utm_source=create-next-app&utm_campaign=create-next-app-readme) from the creators of Next.js.
Check out our [Next.js deployment documentation](https://nextjs.org/docs/deployment) for more details.
This is a starter template for [Learn Next.js](https://nextjs.org/learn).

View File

@@ -3,7 +3,7 @@ import styles from './Layout.module.css'
import utilStyles from '../styles/utils.module.css'
import Link from 'next/link'
const name = 'Shu Uesugi'
const name = '[Your Name]'
export const siteTitle = 'Next.js Sample Website'
const Page = ({ children, home }) => (

View File

@@ -9,17 +9,7 @@ const Home = ({ allPostsData }) => (
<title>{siteTitle}</title>
</Head>
<section className={utilStyles.headingMd}>
<p>
Hello, Im <strong>Shu</strong>. I write code at{' '}
<a href="https://zeit.co">ZEIT</a>, the team behind{' '}
<a href="https://nextjs.org/">Next.js</a>. You can contact me via{' '}
<a href="https://twitter.com/chibicode">Twitter</a> or{' '}
<a href="mailto:chibicode@zeit.co">email</a>.
</p>
<p>
(This is a sample website - youll be building a site like this on{' '}
<a href="https://nextjs.org/learn">our Next.js tutorial</a>.)
</p>
<p>[Your Self Introduction]</p>
</section>
<section className={`${utilStyles.headingMd} ${utilStyles.padding1px}`}>
<h2 className={utilStyles.headingLg}>Blog</h2>

Binary file not shown.

Before

Width:  |  Height:  |  Size: 22 KiB

After

Width:  |  Height:  |  Size: 61 KiB

View File

@@ -6,6 +6,14 @@
margin: 1rem 0;
}
.headingXl {
font-size: 2rem;
line-height: 1.3;
font-weight: 800;
letter-spacing: -0.05rem;
margin: 1rem 0;
}
.headingLg {
font-size: 1.5rem;
line-height: 1.4;