This is a small full-stack web application that can help a freelancer track their time.
- As a user, I want to be able to start a time tracking session
- As a user, I want to be able to stop a time tracking session
- As a user, I want to be able to name my time tracking session
- As a user, I want to be able to save my time tracking session when I am done with it
- As a user, I want an overview of my sessions for the day, week and month
- As a user, I want to be able to close my browser and shut down my computer and still have my sessions visible to me when I power it up again.
The following will need to be implemented before releasing the app to production
- Add E2E tests for the app (mainly around session form)
- Add API tests for controllers
- Add the ability to delete saved sessions
- Implement the ability to create users
- Add user authentication/authorization in both API and Client
- Amend the DB data to handle users
- Improve validation for API requests
- Create CI & CD pipeline
- Host the API & Client
- Implemented using
Express
withTypescript
- Used
MongoDB
for database - Used
Jest
for testing
- Implemented using
ReactJS
withTypescript
- Used
Jest
,react-testing-library
andmsw
for testing - Used
React-bootstrap
for faster, responsive and accessible styling
yarn
To get a local copy up and running follow these simple steps.
- Clone this repo
- Go to the API
cd ./api
- Install dependencies
yarn
- Create
.env
file in the root of the dir - Configure the
.env
file as per the example (.env.example
) with the provided credentials - Run the API
yarn start
- The API will run on
localhost:8000
- Install dependencies
- Open a new terminal window and go to the Client
cd ./client
- Install dependencies
yarn
- Run the client
yarn start
- The client will run on
localhost:3000
- Install dependencies
- You can access the application through
http://localhost:3000
This application is tested using a mix of unit and integration tests. Not everything has been tested due to the time. The next steps would be to test session form using e2e tests (preferably cypress) and also add more tests for the API.
Project is split into multiple directories for better access and easier usage.
.
├── api # All the files related to the API
├── src # API source files
├── db # Database files for connecting MongoDB
├── resources # Main API logic consisting of constructors, models & routes
├── client # All the files related to the client
├── src # Client source files
├── components # Components used throughout the project
├── hooks # Reusable custom hooks
├── layout # Layout file of the app UI
├── pages # Main pages of the app
├── test # Test helper files for mocking API
├── utils # Extra helper files