Thanks to visit codestin.com
Credit goes to github.com

Skip to content

FlySky-z/fs-blog-front

Repository files navigation

This is a Next.js project bootstrapped with create-next-app.

Getting Started

First, run the development server:

npm run dev
# or
yarn dev
# or
pnpm dev
# or
bun dev

Open http://localhost:3000 with your browser to see the result.

You can start editing the page by modifying app/page.tsx. The page auto-updates as you edit the file.

This project uses next/font to automatically optimize and load Geist, a new font family for Vercel.

环境变量配置

项目使用以下环境变量文件来管理不同环境下的配置:

  • .env.development - 开发环境配置,应用于 npm run dev
  • .env.production - 生产环境配置,应用于 npm run buildnpm run start
  • .env.local - 本地配置覆盖(不应提交到版本控制)

可用的环境变量

环境变量 描述 默认值
NEXT_PUBLIC_API_BASE_URL API 服务端点 开发: http://localhost:8000/api
生产: 使用公网 IP
NEXT_PUBLIC_SITE_URL 站点 URL 开发: http://localhost:3000
生产: 使用公网 IP

配置生产环境

部署到生产环境前,请修改 .env.production 文件中的 NEXT_PUBLIC_API_BASE_URLNEXT_PUBLIC_SITE_URL,设置为实际的公网 IP 或域名。

# .env.production 示例
NEXT_PUBLIC_API_BASE_URL=http://your-domain-or-ip:8000/api
NEXT_PUBLIC_SITE_URL=http://your-domain-or-ip

Learn More

To learn more about Next.js, take a look at the following resources:

You can check out the Next.js GitHub repository - your feedback and contributions are welcome!

Deploy on Vercel

The easiest way to deploy your Next.js app is to use the Vercel Platform from the creators of Next.js.

Check out our Next.js deployment documentation for more details.

About

fs blog frontend

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages