Monorepo built with nx
cp apps/frontend/.env.example ./apps/frontend/.env.local
pnpm
pnpm dev
build all packages
pnpm nx run-many --target=build --all
remove a project
npx nx generate @nx/workspace:remove --projectName=<your project name>
generate a new next.js app
npx nx generate @nx/next:application <your application name>
generate a new react library
npx nx generate @nx/react:library <your component name>
.env.example
file to .env
and fill in the required credentials.
a. the defaults should work for fresh local development
b. by default the instance is unsecured and has no permissions or admin secretdocker-compose up -d
to start the Hasura server.This will start the Hasura server on port 8080. Connect the frontend above by using the associated variables.
NEXT_PUBLIC_API_URL='http://localhost:8080/v1/graphql'
HASURA_GRAPHQL_ADMIN_SECRET=
If you want to run a secure instance of Hasura, you can enable the secret, unauthorized role, and JWT authentication. Within the graphql-engine
service enable these variables:
HASURA_GRAPHQL_UNAUTHORIZED_ROLE;
HASURA_GRAPHQL_ADMIN_SECRET;
HASURA_GRAPHQL_JWT_SECRET;
Also enable the HASURA_GRAPHQL_ADMIN_SECRET
variable in the hasura-setup
service, in case migrations need to be run.