Rankflow is a Next.js application that connects to Webflow's CMS, allowing users to manage and optimize their content for search engines using AI.
- Prerequisites
- Getting Started
- Environment Variables
- Available Scripts
- Project Structure
- Coding Standards
- Deployment
- Contributing
Before you begin, ensure you have the following installed:
- Node.js (v18 or later)
- npm (v7 or later)
-
Clone the repository:
git clone https://github.com/your-username/rankflow.git cd rankflow
-
Install dependencies:
npm install
-
Set up environment variables:
- Copy the
.env.example
file to.env.local
- Fill in the required values (see Environment Variables section)
- Copy the
-
Run the development server:
npm run dev
-
Open http://localhost:3000 in your browser to see the application.
-
Make Husky hooks executable:
chmod ug+x .husky/*
Create a .env.local
file in the root directory with the following variables:
NEXT_PUBLIC_SITE_URL=http://localhost:3000 LOGTO_ENDPOINT=your_logto_endpoint LOGTO_APP_ID=your_logto_app_id LOGTO_APP_SECRET=your_logto_app_secret LOGTO_COOKIE_SECRET=your_logto_cookie_secret
npm run dev
: Start the development servernpm run build
: Build the application for productionnpm run start
: Start the production servernpm run lint
: Run ESLint for code qualitynpm run format
: Run Prettier for code formatting
app/
: Contains the Next.js app router pages and layoutscomponents/
: Reusable React componentspublic/
: Static assetsstyles/
: Global styles and Tailwind CSS configuration
This project uses ESLint and Prettier for code linting and formatting. The configuration files are:
.eslintrc.json
: ESLint configuration.prettierrc
: Prettier configuration
We use husky and lint-staged to enforce coding standards before commits.
This project is set up for deployment on Vercel. The next.config.js
file includes the necessary configuration for a standalone output.
To deploy:
- Push your changes to the main branch
- Vercel will automatically deploy the new version
- Fork the repository
- Create a new branch:
git checkout -b feature/your-feature-name
- Make your changes and commit them using conventional commit messages
- Push to your fork and submit a pull request
Please make sure your code adheres to the existing style and passes all tests.
For more detailed guidelines, please refer to the CONTRIBUTING.md
file.