Nota is a note-taking service, which is available on the web. Nota offers users to create notes, and share their notes with their friends.
a stack of express as web application framework for Node.js, sequalize as promise-based ORM for database.
you have to create a database called Nota, run the following command lines
mysql
CREATE DATABASE Nota;
now you need to install the dependencies
cd api
npm i
node app
npm run test
nano .env
Add the following configurations:
SERVER=
your backend server url (e.g. example.com)
PORT=
port (e.g. 3000)
HOST_URL=
http://your_server_url:port (e.g. http://example:3000)
DB_DIALECT=mysql
DB_HOST=
your database url (e.g. example.com)
DB_PORT=
your database port (default is 3306)
DB_USER=
your database username (e.g. root)
DB_PASS=
your databse password
DB_NAME=Nota
JWT_SECRET
= generate your own JWT secret code and save it here.
Mysql database named Nota
it have 2 tables Users
and Note
where a user can create many notes but a note is created by 1 user, also the note can be shared with many users.
NOTE M -> 1
USER
many to 1 relationship
user.id
is a primary keynote.id
is a primary keynote.author
is af.k.
reference touser.username
user.username
is uniqueuser.email
is unique
the front-end is responsive so it works fine on small, medium and large devices.
used a stack of angular as web framework, bootstrap as styling framework
run the following commands:
cd frontend
npm i
ng serve
ng test
edit environment.prod.ts
file as the following
apiHost: http://YOUR_BACKEND_URL:PORT/api/v1/
run the following command to build
ng build --prod