This is a Next.js project bootstrapped
with create-next-app.
First, run the development server:
pnpm run devOpen 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 Inter, a custom Google Font.
lib/config/home.tsx- Home page contentlib/config/pages.tsx- Other pages content
/pricing reads Cloud Pro prices on the server from the public
https://beta.appflowy.cloud/billing/api/v1/pricing catalog. Set the server-only
BILLING_API_BASE_URL to use a different billing deployment. No Stripe credentials
or browser CORS configuration are needed.
Comparison tables, pricing cards, annual savings, FAQ examples, and JSON-LD all use the same response. The API's yearly amount is the full annual charge in cents; only the monthly equivalent is divided by twelve. Self-hosted prices remain local.
Next.js caches the validated catalog and refreshes it after 300 seconds, on incoming requests. Failed requests or invalid catalogs leave the last valid prices available while refreshes retry. If the first request fails with no cached catalog, the page still renders Personal and self-hosted plans and shows Cloud Pro pricing as unavailable. Pro amounts, savings, and structured offers are omitted until billing recovers; the next request retries instead of caching the unavailable state. There are no hard-coded replacement prices. Deploy billing first when rolling out new rates.
We have set up an automated deployment process for the testing environment. When code is merged into either the main
or develop branch, the system automatically deploys the changes to the testing environment. You can find the
deployment workflow configuration in .github/workflows/deploy_dev.yml.
To deploy changes to the production environment, follow these steps:
- Visit the project's GitHub page.
- Navigate to the "Actions" tab.
- Click on "Manual Deploy to Production."
- Select "Run workflow" to initiate a manual deployment to the production environment.
Our testing framework of choice is Cypress. Comprehensive testing information will be provided in this section as the project progresses.
pnpm run build
pnpm run start
pnpm run test
# or
pnpm run test:headlessThe site fetches release and star data from the GitHub API at request time. Unauthenticated requests are limited to
60 per hour per IP, which is easy to exhaust in CI or on shared networks and causes the "What's New" banner test to fail.
Set GITHUB_TOKEN in the server's environment to authenticate those requests and raise the limit (the Test workflow
passes the built-in Actions token automatically).
Feel free to update this README with more details as the project evolves. If you have any questions or need further assistance, please don't hesitate to reach out. Happy coding!