DevEvents is a web application for browsing, creating, and managing events (e.g., hackathons, meetups, conferences) related to software development.
| Build | Tests | Coverage |
|---|---|---|
- Next.js version 16
- MongoDB
- Cloudinary
- PostHog
- Tailwind CSS
- Bun
- Biome
- Vitest
- React Testing Library
- GitHub Actions
This project uses Bun as a package manager, so you'll need to install that if you don't already have it installed. Using another package manager (e.g., npm, yarn) would result in creating another lockfile for dependencies, which could result in conflicts and is therefore not recommended.
Install project dependencies with the following command.
$ bun install- Create a
.envfile. - Copy the contents of the
.env.examplefile into the.envfile. - Add values for any variables that are blank (e.g., API keys).
To run the development server, run the following command.
$ bun run devThis will start a development server at http://localhost:3000.
The endpoints directory includes YAML files for API endpoint testing. They can be opened with Yaak, a free API client that enables syncing workspace data to the local filesystem.
In the app, you can choose to open an existing workspace and select the endpoints directory when doing so. This will load the workspace and all of the requests within it.
If any local changes are made to the existing requests, or if new requests are added, those changes will be automatically tracked by Git and can be discarded or committed as needed.
Test coverage is created by Vitest and sent to Codecov via a GitHub action. This is the source of the Coverage badge in the Project Status section.
To run tests locally with Vitest, run the following command.
$ bun run test- Create a free PostHog account if you don't have one already.
- You'll be asked to create an organization. Set whatever organization name you want and continue.
- Select all products to use.
- Skip the installation for the
Installstep.
- On your dashboard, click the project dropdown in the top left and click the settings icon next to the project name (this will be
Default projectif you're a new user).- If you already have an account, create a new project.
- (Optional) Set
Display nametoDevEvents, or whatever name you'd like to call the project. - Scroll down to the bottom of the
Generaltab and copy yourProject API key. Set that value as the value forNEXT_PUBLIC_POSTHOG_KEYin your.envfile. - Use the PostHog documentation to create insights and dashboards, turn on error tracking, etc.
- Create a free MongoDB Atlas account if you don't have one already.
- Create a new project.
- Create a cluster.
- Choose the free tier.
- Select the region that's closest to you.
- Click
Create Deployment.
- Click
Create Database User. - Click
Choose a connection method. - Click
DriversunderConnect to your application. - Wait for the cluster to finish provisioning, and then copy the connection string. Set it as the value for the
MONGODB_URIvariable in your.envfile. - In the side navigation, click
Database and Network AccessunderneathSecurity.- Click on
IP Access List. - Click
Add IP Address. - Click
Allow Access from Anywhereand clickConfirm.- This is necessary for connecting after deployment.
- Click on
- Create a free Cloudinary account if you don't have one already.
- Go through the onboarding if you've just created an account.
- Click on the settings icon in the side navigation.
- Click on
Upload, then click onAdd Upload Preset.- Provide any preset name you'd like.
- Set
Signing modeasUnsigned. - Set
Foldertoevents. - Click
Save.
- Click on
API Keysin the navigation.- Copy the
CLOUDINARY_URLvalue in theAPI environment variablesection and paste it as the value for theCLOUDINARY_URLenvironment variable in your.envfile. - Click
Generate New API Key. Enter the confirmation code sent to your email. - Copy the
API Keyvalue shown in the table and replace<your_api_key>in yourCLOUDINARY_URLvalue with the key you just copied. - Copy the
API Secretvalue shown in the table and replace<your_api_secret>in yourCLOUDINARY_URLwith the secret you just copied. - (Optional) You can rename your API key to something more specific, rather than leaving the default key name of
Untitled.
- Copy the