git clone https://github.com/Kuzma02/MERN-Login-And-Register-With-JSON-Web-Token.git
cd folder-name
npm install
cd client
npm install
- Visit the MongoDB website, create an account, a database, and copy the connection string.
- Generate a 256-bit random key and add it to the
.env
file. Create the.env
file in the root directory with the following contents:
MONGO_URI=your_mongodb_uri
JWT_SECRET=your_jwt_secret
node app.js
cd client
npm run dev
Open your browser and navigate to:
http://localhost:5173
- This project uses Node.js version 20. To use it, run:
nvm use 20
- In the
client
repository, install the libraries required for the QR scanner:
npm install html5-qrcode --legacy-peer-deps
- Then, run
npm run dev
in theclient
directory.
If you encounter any issues or have further questions, please refer to the project's README or open an issue on the GitHub repository.