Welcome to the Next.js and Lingui static site generation (SSG) template project! This repository demonstrates the state-of-the-art integration of Next.js and Lingui for creating static web apps with multi-lingual support.
Next.js, a powerful React framework, is designed to build server-rendered React applications and SSG sites. In this context, we're utilizing Next.js's Static Site Generation capabilities to pre-render pages at build time.
Combined with Lingui, an i18n (internationalization) library for JavaScript, we've endeavored to produce a multilingual static website that effectively caters to a global audience.
Our aim with this template project is to illustrate the procedure of building an international static web app that is performant, SEO-advantaged, and maintains simplified translation management, courtesy of the capabilities brought about by the coupling of Next.js's SSG and Lingui.
- Static Site Generation with Next.js: Experience the unique advantages of utilizing Next.js in our static web application. This includes benefits such as improved performance and SEO, client-side routing, and a more streamlined development process.
- Translation Management with Lingui: Discover how Lingui simplifies handling translations in our static web app, from message extraction to language pluralization and localized formatting.
- Real-time Language Switching: Experience an interactive feature of our static web app that enables dynamic language switching. This allows users to effortlessly switch between different languages without navigating away from their current page.
Click on Use this template
to create the repo for your app.
Then, to use this project template, follow these steps:
- Clone this repository:
git clone https://github.com/your-username/your-repo.git
- Navigate to the project directory:
cd your-repo
- Install project dependencies:
pnpm install
- Start the development server:
pnpm run dev
- Open your browser and visit http://localhost:3000 to see the application in action.
We welcome contributions to this project! To contribute, follow these steps:
- Fork the repository
- Create a new branch:
git checkout -b your-feature
- Make your changes and commit them:
git commit -m "Add your feature"
- Push to the branch:
git push origin your-feature
- Open a pull request to the main branch of this repository
This project is licensed under the Apache License - see the LICENSE file for details.