Glific is a two-way communication platform built for nonprofits. This is the frontend interface built using React.
- Pre-requisite
- Clone Frontend Repo
- Installation
- Available Scripts
- Docker Image for Production
- Localization
- Deploying Release on ECS with CD
- Learn More
asdf plugin-add nodejs
asdf install nodejs latest
asdf set -u nodejs latest
npm install --global yarn
git clone git@github.com:glific/glific-frontend.git
You need to set up the backend service for Glific. Follow the instructions here:
π https://github.com/glific/glific
π‘ Note: SSL is required in development for both frontend and backend. Follow the SSL setup instructions in the backend README.
Also, add the following entry to your /etc/hosts
file:
127.0.0.1 glific.test
-
Copy
.env.example
to.env
in the project root:cp .env.example .env
-
Do not modify
.env
unless absolutely required. -
Install dependencies:
yarn setup
Ensure your Glific backend server is running and accessible.
yarn dev
Visit https://glific.test:3000
to open the app.
-
Phone: 917834811114
-
Password: Secret1234!
After logging in:
This step is required only if you're using Gupshup integration and have ISV credentials stored in the database.
- Go to Settings β Integration.
- Enter your Gupshup credentials and App Name.
- Save the settings to auto-fetch your Gupshup App ID.
π‘ Note: Auto-fetching the App ID will only work if valid ISV credentials are already present in the backend database.
yarn setup # Install dependencies
yarn dev # Run app in development mode
yarn test # Run tests in watch mode
yarn test:coverage # Run tests with coverage
yarn build # Create optimized production build
yarn extract-translations # Extract English strings for Lokalise
To build a production Docker image:
docker build \
--build-arg VITE_GLIFIC_API_PORT=API-PORT \
--no-cache -t glific-frontend .
Replace API-PORT
with your backend API port number.
-
Extract base strings:
yarn extract-translations
-
Once merged into
main
, strings will appear in Lokalise. -
Use
Download β Build only
in Lokalise to push translations. -
This will create a PR automatically in the frontend repo.
-
It's recommended to Preview before building.
- For AWS CodeBuild, use
buildspec.yml.sample
as your config file. - For Docker Hub and alternatives, use this GitHub Action:
π https://github.com/marketplace/actions/build-and-push-docker-images
- π Glific.org
- π One Pager
- π Google Drive
- π Product Features
- π° Blogs
- π¬ Discord