-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
39 changed files
with
3,609 additions
and
1,896 deletions.
There are no files selected for viewing
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,8 +1,6 @@ | ||
node_modules/ | ||
dist/ | ||
.vercel/ | ||
|
||
!.*rc.js | ||
!.*rc.mjs | ||
!.*rc.cjs | ||
|
||
.next/ | ||
out/ | ||
!.*rc.[mc]js |
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,26 @@ | ||
/** @type {import("eslint").Linter.Config} */ | ||
module.exports = { | ||
extends: [ | ||
"eslint:recommended", | ||
"airbnb-base", | ||
"plugin:astro/recommended", | ||
"plugin:astro/jsx-a11y-strict", | ||
"prettier", | ||
], | ||
rules: { "import/no-unresolved": [2, { ignore: ["^@astrojs/"] }] }, | ||
overrides: [ | ||
{ | ||
// Define the configuration for `.astro` file. | ||
files: ["*.astro"], | ||
// Allows Astro components to be parsed. | ||
parser: "astro-eslint-parser", | ||
// Parse the script in `.astro` as TypeScript by adding the following configuration. | ||
// It's the setting you need when using TypeScript. | ||
parserOptions: { | ||
parser: "@typescript-eslint/parser", | ||
project: "tsconfig.json", | ||
extraFileExtensions: [".astro"], | ||
}, | ||
}, | ||
], | ||
}; |
This file was deleted.
Oops, something went wrong.
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,36 +1,24 @@ | ||
# See https://help.github.com/articles/ignoring-files/ for more about ignoring files. | ||
# build output | ||
dist/ | ||
|
||
# dependencies | ||
/node_modules | ||
/.pnp | ||
.pnp.js | ||
|
||
# testing | ||
/coverage | ||
|
||
# next.js | ||
/.next/ | ||
/out/ | ||
# generated types | ||
.astro/ | ||
|
||
# production | ||
/build | ||
|
||
# misc | ||
.DS_Store | ||
*.pem | ||
# dependencies | ||
node_modules/ | ||
|
||
# debug | ||
# logs | ||
npm-debug.log* | ||
yarn-debug.log* | ||
yarn-error.log* | ||
.pnpm-debug.log* | ||
pnpm-debug.log* | ||
|
||
# local env files | ||
.env*.local | ||
# environment variables | ||
.env | ||
.env.production | ||
|
||
# vercel | ||
.vercel | ||
# macOS-specific files | ||
.DS_Store | ||
|
||
# typescript | ||
*.tsbuildinfo | ||
next-env.d.ts | ||
# vercel | ||
.vercel/ |
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,8 +1,7 @@ | ||
const eslint = "eslint --fix"; | ||
const prettier = "prettier --write"; | ||
const prettierCheck = "prettier --check"; | ||
|
||
module.exports = { | ||
"*.{js,mjs,cjs,jsx,ts,mts,cts,tsx,vue}": [eslint, prettierCheck], | ||
"*.{md,css,scss,json,yml,yaml,gql,graphql}": prettier, | ||
"*.{astro,js,mjs,cjs,ts}": [prettier, eslint], | ||
"*.{md,html,json,yml,yaml}": prettier, | ||
}; |
This file was deleted.
Oops, something went wrong.
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,6 +1,4 @@ | ||
node_modules/ | ||
|
||
dist/ | ||
.vercel/ | ||
pnpm-lock.yaml | ||
|
||
.next/ | ||
out/ |
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,14 @@ | ||
/* eslint-disable global-require */ | ||
module.exports = { | ||
plugins: [require("prettier-plugin-tailwindcss")], | ||
plugins: [ | ||
require.resolve("prettier-plugin-astro"), | ||
require.resolve("prettier-plugin-tailwindcss"), | ||
], | ||
overrides: [ | ||
{ | ||
files: "*.astro", | ||
options: { | ||
parser: "astro", | ||
}, | ||
}, | ||
], | ||
}; |
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,9 @@ | ||
{ | ||
"recommendations": [ | ||
"astro-build.astro-vscode", | ||
"bradlc.vscode-tailwindcss", | ||
"dbaeumer.vscode-eslint", | ||
"esbenp.prettier-vscode" | ||
], | ||
"unwantedRecommendations": [] | ||
} |
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,11 @@ | ||
{ | ||
"version": "0.2.0", | ||
"configurations": [ | ||
{ | ||
"command": "./node_modules/.bin/astro dev", | ||
"name": "Development server", | ||
"request": "launch", | ||
"type": "node-terminal" | ||
} | ||
] | ||
} |
This file was deleted.
Oops, something went wrong.
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,34 +1,54 @@ | ||
This is a [Next.js](https://nextjs.org/) project bootstrapped with [`create-next-app`](https://github.com/vercel/next.js/tree/canary/packages/create-next-app). | ||
# Astro Starter Kit: Basics | ||
|
||
## Getting Started | ||
``` | ||
npm create astro@latest -- --template basics | ||
``` | ||
|
||
First, run the development server: | ||
[![Open in StackBlitz](https://developer.stackblitz.com/img/open_in_stackblitz.svg)](https://stackblitz.com/github/withastro/astro/tree/latest/examples/basics) | ||
[![Open with CodeSandbox](https://assets.codesandbox.io/github/button-edit-lime.svg)](https://codesandbox.io/p/sandbox/github/withastro/astro/tree/latest/examples/basics) | ||
[![Open in GitHub Codespaces](https://github.com/codespaces/badge.svg)](https://codespaces.new/withastro/astro?devcontainer_path=.devcontainer/basics/devcontainer.json) | ||
|
||
```bash | ||
npm run dev | ||
# or | ||
yarn dev | ||
``` | ||
> 🧑🚀 **Seasoned astronaut?** Delete this file. Have fun! | ||
Open [http://localhost:3000](http://localhost:3000) with your browser to see the result. | ||
![basics](https://user-images.githubusercontent.com/4677417/186188965-73453154-fdec-4d6b-9c34-cb35c248ae5b.png) | ||
|
||
You can start editing the page by modifying `pages/index.tsx`. The page auto-updates as you edit the file. | ||
## 🚀 Project Structure | ||
|
||
[API routes](https://nextjs.org/docs/api-routes/introduction) can be accessed on [http://localhost:3000/api/hello](http://localhost:3000/api/hello). This endpoint can be edited in `pages/api/hello.ts`. | ||
Inside of your Astro project, you'll see the following folders and files: | ||
|
||
``` | ||
/ | ||
├── public/ | ||
│ └── favicon.svg | ||
├── src/ | ||
│ ├── components/ | ||
│ │ └── Card.astro | ||
│ ├── layouts/ | ||
│ │ └── Layout.astro | ||
│ └── pages/ | ||
│ └── index.astro | ||
└── package.json | ||
``` | ||
|
||
The `pages/api` directory is mapped to `/api/*`. Files in this directory are treated as [API routes](https://nextjs.org/docs/api-routes/introduction) instead of React pages. | ||
Astro looks for `.astro` or `.md` files in the `src/pages/` directory. Each page is exposed as a route based on its file name. | ||
|
||
## Learn More | ||
There's nothing special about `src/components/`, but that's where we like to put any Astro/React/Vue/Svelte/Preact components. | ||
|
||
To learn more about Next.js, take a look at the following resources: | ||
Any static assets, like images, can be placed in the `public/` directory. | ||
|
||
- [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. | ||
## 🧞 Commands | ||
|
||
You can check out [the Next.js GitHub repository](https://github.com/vercel/next.js/) - your feedback and contributions are welcome! | ||
All commands are run from the root of the project, from a terminal: | ||
|
||
## Deploy on Vercel | ||
| Command | Action | | ||
| :--------------------- | :----------------------------------------------- | | ||
| `npm install` | Installs dependencies | | ||
| `npm run dev` | Starts local dev server at `localhost:3000` | | ||
| `npm run build` | Build your production site to `./dist/` | | ||
| `npm run preview` | Preview your build locally, before deploying | | ||
| `npm run astro ...` | Run CLI commands like `astro add`, `astro check` | | ||
| `npm run astro --help` | Get help using the Astro CLI | | ||
|
||
The easiest way to deploy your Next.js app is to use the [Vercel Platform](https://vercel.com/new?utm_medium=default-template&filter=next.js&utm_source=create-next-app&utm_campaign=create-next-app-readme) from the creators of Next.js. | ||
## 👀 Want to learn more? | ||
|
||
Check out our [Next.js deployment documentation](https://nextjs.org/docs/deployment) for more details. | ||
Feel free to check [our documentation](https://docs.astro.build) or jump into our [Discord server](https://astro.build/chat). |
This file was deleted.
Oops, something went wrong.
Oops, something went wrong.
3330073
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Successfully deployed to the following URLs:
wxh-im – ./
wxh-im-git-main-wangxinhe.vercel.app
wxh-im-wangxinhe.vercel.app
wxh-im.vercel.app
wxh.im