This is the default frontend for the Sublinks project. It's built using the NextJS framework and React library.
Together with the Sublinks Core and Sublinks Federation it's creating a federated link aggregation and microblogging platform.
Please post any feature requests or bug reports in the repository's Issues section.
Before you start be aware that NextJS has started collecting telemetry data when using it.
Here's how you can opt-out: https://nextjs.org/telemetry#how-do-i-opt-out
- Node version >=20.0.0
- NPM version >=9.0.0
Install dependencies
npm iTo run this project, you need to set up the necessary environment variables. A template for these variables can be found in the .env.example file.
A Docker Compose configuration is made available via a git submodule. This provides an environment which contains a real connection to the Sublinks API and other services. As close to a production-like environment we can test and develop towards locally.
To use this Docker setup you first need to complete a few steps:
- Authenticate towards GitHub's container registry(GHCR)
- Please follow this guide to create an access token and authenticate before running the below command.
- Run
git submodule update --init --recursiveto pull down all submodules - Run
git submodule update --recursive --remoteafter the initial pull to receive the latest submodule changes
npm run dev:dockerThis will expose a NextJS dev environment at http://localhost. It also runs a seeding script which inserts several data entities on startup. To give you something to work with, without having to manually create users and such.
npm run devThis will expose a NextJS dev environment at http://localhost:3000. It makes no API requests and instead uses a couple test data files.
Lint
npm run lintUnit Tests
npm run test:unit
npm run test:unit:watchE2E Tests
TBDTBD