From b9e9263a92c7f46b4e610d220596230b5f8195ba Mon Sep 17 00:00:00 2001 From: QkoSad Date: Mon, 30 Sep 2024 15:43:55 +0300 Subject: [PATCH] README updated and packages upgraded --- .gitignore | 1 - README.md | 11 +++++ backend/.env | 4 ++ .../package-lock.json | 0 package.json => backend/package.json | 5 +- frontend/README.md | 46 ------------------- 6 files changed, 17 insertions(+), 50 deletions(-) create mode 100644 README.md create mode 100644 backend/.env rename package-lock.json => backend/package-lock.json (100%) rename package.json => backend/package.json (78%) delete mode 100644 frontend/README.md diff --git a/.gitignore b/.gitignore index 37d7e73..3c3629e 100644 --- a/.gitignore +++ b/.gitignore @@ -1,2 +1 @@ node_modules -.env diff --git a/README.md b/README.md new file mode 100644 index 0000000..2d6b8a1 --- /dev/null +++ b/README.md @@ -0,0 +1,11 @@ +# Support Desk +--- +>React web app for support tickets. It allows creating user profiles and tickets. +>Frontend is react. Back end is express and db is mongo with mongoose. +--- +## Usage: +In the back end directory +`npm run sever` +In the front end directory +`npm start` +It requires a mongodb instance running at: mongodb://127.0.0.1:27017/ diff --git a/backend/.env b/backend/.env new file mode 100644 index 0000000..9c29557 --- /dev/null +++ b/backend/.env @@ -0,0 +1,4 @@ +NODE_ENV = development +PORT = 5000 +MONGO_URI = mongodb://127.0.0.1:27017/support-desk +JWT_SECRET = abc123 diff --git a/package-lock.json b/backend/package-lock.json similarity index 100% rename from package-lock.json rename to backend/package-lock.json diff --git a/package.json b/backend/package.json similarity index 78% rename from package.json rename to backend/package.json index 91058ac..8de269a 100644 --- a/package.json +++ b/backend/package.json @@ -4,9 +4,8 @@ "description": "", "main": "server.js", "scripts": { - "start": "node backend/server.js", - "server": "nodemon backend/server.js", - "client": "npm start --prefix frontend" + "start": "node server.js", + "server": "nodemon server.js" }, "author": "", "license": "ISC", diff --git a/frontend/README.md b/frontend/README.md deleted file mode 100644 index de6c0e1..0000000 --- a/frontend/README.md +++ /dev/null @@ -1,46 +0,0 @@ -# Getting Started with Create React App and Redux - -This project was bootstrapped with [Create React App](https://github.com/facebook/create-react-app), using the [Redux](https://redux.js.org/) and [Redux Toolkit](https://redux-toolkit.js.org/) template. - -## Available Scripts - -In the project directory, you can run: - -### `npm start` - -Runs the app in the development mode.\ -Open [http://localhost:3000](http://localhost:3000) to view it in your browser. - -The page will reload when you make changes.\ -You may also see any lint errors in the console. - -### `npm test` - -Launches the test runner in the interactive watch mode.\ -See the section about [running tests](https://facebook.github.io/create-react-app/docs/running-tests) for more information. - -### `npm run build` - -Builds the app for production to the `build` folder.\ -It correctly bundles React in production mode and optimizes the build for the best performance. - -The build is minified and the filenames include the hashes.\ -Your app is ready to be deployed! - -See the section about [deployment](https://facebook.github.io/create-react-app/docs/deployment) for more information. - -### `npm run eject` - -**Note: this is a one-way operation. Once you `eject`, you can't go back!** - -If you aren't satisfied with the build tool and configuration choices, you can `eject` at any time. This command will remove the single build dependency from your project. - -Instead, it will copy all the configuration files and the transitive dependencies (webpack, Babel, ESLint, etc) right into your project so you have full control over them. All of the commands except `eject` will still work, but they will point to the copied scripts so you can tweak them. At this point you're on your own. - -You don't have to ever use `eject`. The curated feature set is suitable for small and middle deployments, and you shouldn't feel obligated to use this feature. However we understand that this tool wouldn't be useful if you couldn't customize it when you are ready for it. - -## Learn More - -You can learn more in the [Create React App documentation](https://facebook.github.io/create-react-app/docs/getting-started). - -To learn React, check out the [React documentation](https://reactjs.org/).