Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
23 changes: 23 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
# See https://help.github.com/articles/ignoring-files/ for more about ignoring files.

# dependencies
/node_modules
/.pnp
.pnp.js

# testing
/coverage

# production
/build

# misc
.DS_Store
.env.local
.env.development.local
.env.test.local
.env.production.local

npm-debug.log*
yarn-debug.log*
yarn-error.log*
3 changes: 3 additions & 0 deletions .idea/.gitignore

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

10 changes: 10 additions & 0 deletions .idea/categories.iml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

6 changes: 6 additions & 0 deletions .idea/jsLibraryMappings.xml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

5 changes: 5 additions & 0 deletions .idea/misc.xml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

8 changes: 8 additions & 0 deletions .idea/modules.xml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

6 changes: 6 additions & 0 deletions .idea/vcs.xml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

12 changes: 12 additions & 0 deletions .vscode/launch.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
{
"version": "0.2.0",
"configurations": [
{
"type": "pwa-chrome",
"request": "launch",
"name": "Launch Chrome against localhost",
"url": "http://localhost:8080",
"webRoot": "${workspaceFolder}"
}
]
}
106 changes: 81 additions & 25 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,38 +1,94 @@
# Flex Business Solutions Tech Test - Notes app
# My Notes App

In Flex Business Solutions, we aim to provide excellence and efficiency on all our lines of code in order to support the day-to-day activities of the company using our software solutions. In this task, you will be provided with a simple design of an app, fetching a list of products from an external source and allowing the user to search or filter among the list.
A React-based web application where users can register, login, and manage their notes organized by categories.

## Features

### Tech Test Overview
We have provided below the Figma link of this task. On the main page,
- User Registration and Login with JWT Authentication.
- Create unlimited categories to organize your notes.
- Add as many notes as desired inside any category.
- Edit or delete your notes anytime.
- Logout from the application.

[FIGMA] [https://www.figma.com/file/T6hUVUDh5ihoYwQILcJDcf/React-Home-Test?type=design&node-id=0%3A1&mode=design&t=lOTjaPb3chxGqXkY-1]
## Technologies Used

We love to see:
- Functional code
- Good design
- Unit testing
- React.js: Frontend library.
- MongoDB: Database to store users, categories, and notes.
- Express.js: Backend framework to handle API requests.
- Node.js: Runtime environment for executing JavaScript server-side.
- Axios: Promise based HTTP client for the browser and Node.js.
- React Router: For managing routes in the React application.
- Redux: For state management.
- JWT (JSON Web Tokens): For secure user authentication.
- React Toast: For displaying notifications.
- Bootstrap: UI framework for styling and components.

## Getting Started

### Notes
All of you work should take place inside this repository.
### Prerequisites

You are free to use any packages that would help with this task
- Make sure you have `Node.js` and `MongoDB` installed on your machine.

You do not need to add additional security measures as part of this exercise.
We're interested in how you break down the work and build your solution in a clean, easy-to-use, reusable and testable manner.
### Installation

1. Clone the repository:

## Deliverables
You must follow the Figma design and need to add the functionality of:
a) Create new notes
c) Show all notes
b) Search notes
```bash
git clone
```

2. Install the necessary npm packages for the frontend:

```bash
cd [your repository name]
npm install
```

3. To run the frontend:

```bash
npm start
```

4. For the backend, navigate to the server directory and start the server:

```bash
cd server
node server.js
```
## Usage

1. Open the application in your browser, at `http://localhost:3002`.
2. Register as a new user or login if you've already registered.
3. Start creating categories and adding notes inside them. You can also edit or delete notes as required.
4. Logout from the application when done.

## Screenshots

Here's a look at the application:

| ![Screenshot 1](./assets/ssh_1.png) | ![Screenshot 2](./assets/ssh_2.png) |
| ---------------------------------- | ---------------------------------- |
| ![Screenshot 3](./assets/ssh_3.png) | ![Screenshot 4](./assets/ssh_4.png) |
| ![Screenshot 5](./assets/ssh_5.png) | ![Screenshot 6](./assets/ssh_6.png) |
| ![Screenshot 7](./assets/ssh_7.png) | ![Screenshot 8](./assets/ssh_8.png) |

## Enhancements & Scalability

### Security Enhancements

1. **Data Encryption**: Ensure end-to-end encryption for sensitive data during transmission and storage.
3. **API Protections**: Incorporate rate limiting and validate/sanitize input to prevent malicious activities.
5. **Infrastructure Defense**: Protect databases and critical endpoints from direct exposure to the internet.
6. **Dependency Management**: Regularly update dependencies to address known vulnerabilities.

### Scalability Strategies

1. **Database Strategies**: Implement effective indexing in MongoDB and consider sharding for larger loads.
2. **Caching**: Use caching systems like Redis to reduce direct database reads.
3. **Load Balancers**: Distribute incoming traffic across multiple app instances for balance.
4. **Utilize CDNs**: Serve static assets via Content Delivery Networks for reduced latency.
5. **Microservices**: Refactor into a microservices architecture to scale different functionalities independently.
6. **Optimized Queries**: Continuously optimize database queries for efficiency.

**Create a folder inside the repository and include finished screenshots of the app.**
**Please make sure to update the readme with**:

- How to run your app with all the necessary details
- Relating to the task please add answers to the following questions;
1. How might you make this app more secure?
2. How would you make this solution scale to millions of records?
Binary file added assets/ssh_1.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added assets/ssh_2.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added assets/ssh_3.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added assets/ssh_4.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added assets/ssh_5.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added assets/ssh_6.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added assets/ssh_7.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added assets/ssh_8.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading