This website is built using Docusaurus, a modern static website generator.
Make sure all dependencies are installed by running:
pnpm install
To start a local development server and open a browser window, run:
pnpm start
Most changes are reflected live without having to restart the server.
To generate static content into the build
directory, run:
pnpm run build
This static content can be served using any static content hosting service.
Using SSH:
USE_SSH=true pnpm run deploy
Not using SSH:
GIT_USER=<Your GitHub username> pnpm run deploy
If you are using GitHub Pages for hosting, this command is a convenient way to build the website and push to the gh-pages
branch.
Docusaurus supports internationalization (i18n) to translate your site into different languages.
-
Ensure your
docusaurus.config.js
is properly configured for i18n:module.exports = { i18n: { defaultLocale: 'en', locales: ['en', 'fr', 'fa'], localeConfigs: { en: { label: 'English', direction: 'ltr', htmlLang: 'en-US', calendar: 'gregory', path: 'en', }, fr: { label: 'French', direction: 'ltr', htmlLang: 'fr-FR', calendar: 'gregory', path: 'fr', }, fa: { label: 'فارسی', direction: 'rtl', htmlLang: 'fa-IR', calendar: 'persian', path: 'fa', }, }, }, };
-
Run the write-translations command:
- For English:
pnpm docusaurus write-translations --locale en
- For French:
pnpm docusaurus write-translations --locale fr
- For Farsi/Persian:
pnpm docusaurus write-translations --locale fa
- For English:
Note: When working with translations, ensure that the i18n
configuration in your docusaurus.config.js
file is correctly set up.
To see your translated files on your local server, follow these steps:
-
Build your project:
pnpm run build
-
Serve the built project:
npm run serve
This will serve the static content generated in the build
directory.