Features
Translation App
- Translates content between different locales in Hygraph
- Supports multiple target locale selection
- Real-time validation and error handling
- Progress indicators and success/error notifications
- Secure API key management
Storefront Field
- Dynamic storefront selection based on tenant
- Auto-selection for single storefront scenarios
- Real-time updates with tenant changes
- Form-compatible multi-select component
Setup
- Clone the repository.
- Install dependencies:
npm install - Create a
.envfile with required environment variables:HYGRAPH_ENDPOINT=your_hygraph_endpoint HYGRAPH_TOKEN=your_hygraph_token
- Run the development server:
npm run dev
Configuration
Translation App
The Translation App requires the following configuration in Hygraph:
- Create a new App in Hygraph.
- Configure the app with:
- Endpoint URL
- Secret key for authentication
- Add the Translation sidebar to your content model.
Storefront Field
To use the Storefront Field:
- Add the field to your content model.
- Configure the tenant relationship.
- Set up the available storefronts per tenant.