Wiki and Setup Guide
Please use NodeJS v18.20.3/Hydrogen (recommended) or higher for this project.
PART I
Clone the front-end and backend project
Copy the repository using the following command and directly go to the right directory:
git clone https://github.com/JoaoVitorFigueiredo/colareseditora.git && cd colareseditoraInstall project dependencies
npm installStart the development front-end server
npm startNote: If any of the required ports are already in use, you can change them in the package.json file under the start script. For example:
"start": "PORT=4000 react-scripts start"PART II
Go to backend project directory
cd backendCreate an enviroment file
If you're using Linux or MacOS you can use the following command in the terminal.
touch .envIf you're using Windows you can use the following command in the terminal.
echo > .envCopy the enviroment structure and add the following below.
MONGO_URI = "mongodb+srv://pawcProject:hXhsG06lFeIkGncn@projects.byvvekw.mongodb.net/"
SECRET_KEY = "34a43495d1e41aa64d5651b028d8cc1237c083f4a609b370165e66665f87d35a"Note: You can also use your own Secret Key, learn how by following this link: Generating a 32-byte string.
If you want to use your own Mongo DB URI and data, download mongo_db.json and upload into your books collection inside your Database in Mongo Compass Application.
Install a virtual enviroment
If you don't have the module to allow certain dependencies, use pip install virtualenv.
python -m venv venv
.\venv\Scripts\activateInstall all the necessary python modules into the backend
python -m pip install Flask
pip install pymongo
pip install -U flask-cors
pip install python-dotenv
pip install pyJWTStart the development backend-end server and pack and go!
flask --app app run --debugNote: Default port is 5000. If default is already in use, you can change it with --port <new port>.
flask --app app run --debug --port 5001Developer Local Development of this docs: colareseditora-docs (opens in a new tab).
If you want to check the legacy and deprecated setup check:
Version V1