This project is divided into two parts:
- Backend:
- Frontend:
- Frontend is developed in React with Redux.
- For UI framework, I have used Material UI.
- See the installation guide for frontend here.
-
To install the libraries
cd Frontendnpm install
-
Testing/Development
- For testing, you need to run the API server.
- Inside
Frontend/src/axiosInstance.jsmodify thebaseURLparameter to your API server's URL. - Also you have to modify
debugparameter ofBackend/config.js. That will sendAccess-Control-Allow-Originheader in response, so frontend can read the respose of cross-origin requests. - You can also use proxy in React. Example here.
-
Build
npm run build
-
Adding the frontend static files
- Build the React Web App.
- Inside frontend folder, a directory named
buildwill be generated. - Copy that directory and paste in the Backend folder.
-
Installation of LaTeX software/library
- I have used miktex which lets us compile the LaTeX file and generate the PDF. (You can use miktex in Windows too)
- Make sure that you can execute the command
pdflatexin your terminal, if not open Environment Variables and add the installed directory's location inPathvariable. - If you need some extra packages like ragged2e and listings, create a directory and put all the downloaded packages there. Open the
config.jsfile inside Backend directory and change the variablelatexPackagesDirectory.
-
Installation of node modules
- Execute this command to install libraries:
npm i
- Execute this command to install libraries:
-
Modification
- Open
index.jsand in thesessionInfodictionary, changesecretvariable's value to some random string. - Inside
dbSync.js, you can add titles of assignments. - Modify
config.jsfor database credentials. - I have used Sequelize ORM library which can be used with MySQL, SQLite, Postgres, MS SQL...
- I have used MySQL in this project. If you want to use other Database, read this documentation.
- Open
-
Run
node .
