diff --git a/README.md b/README.md index 5835f92..9053d0d 100644 --- a/README.md +++ b/README.md @@ -4,28 +4,23 @@ #### Backend for the Alcoding Web Portal - ### Requirements -- [Node.js](https://nodejs.org/en/) 10+ -- [MongoDB](https://docs.mongodb.com/manual/installation/) +- [Node.js](https://nodejs.org/en/) 10+ +- [MongoDB](https://docs.mongodb.com/manual/installation/) ### Setup -- Install dependencies: ``` npm install ``` - - -**Note:** Make sure to add a `config.js` file in the `src` folder. See the `config.example.js` under `src/` directory for more details. - +- Install dependencies: `npm install` +**Note:** Make sure to add a `config.ts` file in the `src` folder. See the `config.example.ts` under `src/` directory for more details. ### Instructions: Development mode: -```npm run start:dev``` +`npm run start:dev` Production mode: -```npm run start``` - +`npm run start` Follow the guide [here](https://khalilstemmler.com/blogs/tooling/prettier/) to configure prettier for your IDE. diff --git a/package.json b/package.json index 6e47b37..4880d2c 100644 --- a/package.json +++ b/package.json @@ -1,62 +1,62 @@ { - "name": "posterior", - "version": "1.0.0", - "description": "Backend for the Alcoding Web portal", - "main": "app.js", - "scripts": { - "start:dev": "nodemon", - "build": "rimraf ./build && tsc", - "start": "npm run build && node build/app.js", - "lint": "eslint . --ext .ts", - "lint-and-fix": "eslint . --ext .ts --fix", - "prettier-format": "prettier --config .prettierrc 'src/**/*.ts' --write", - "prettier-watch": "onchange 'src/**/*.ts' -- prettier --write {{changed}}" - }, - "husky": { - "hooks": { - "pre-commit": "npm run prettier-format && npm run lint" - } - }, - "repository": { - "type": "git", - "url": "git+https://github.com/pes-alcoding-club/posterior.git" - }, - "keywords": [ - "alcoding", - "backend" - ], - "author": "pes-alcoding-club", - "license": "ISC", - "bugs": { - "url": "https://github.com/pes-alcoding-club/posterior/issues" - }, - "homepage": "https://github.com/pes-alcoding-club/posterior#readme", - "dependencies": { - "express": "^4.17.1", - "jsonwebtoken": "^8.5.1", - "mongoose": "^5.9.22", - "passport": "^0.4.1", - "passport-jwt": "^4.0.0", - "passport-local": "^1.0.0", - "passport-local-mongoose": "^6.0.1" - }, - "devDependencies": { - "@types/express": "^4.17.7", - "@types/mongoose": "^5.7.31", - "@types/node": "^14.0.22", - "@types/passport": "^1.0.4", - "@types/passport-jwt": "^3.0.3", - "@types/passport-local": "^1.0.33", - "@types/passport-local-mongoose": "^4.0.13", - "@typescript-eslint/eslint-plugin": "^3.6.0", - "@typescript-eslint/parser": "^3.6.0", - "eslint": "^7.4.0", - "husky": "^4.2.5", - "nodemon": "^2.0.4", - "onchange": "^7.0.2", - "prettier": "^2.0.5", - "rimraf": "^3.0.2", - "ts-node": "^8.10.2", - "typescript": "^3.9.6" - } + "name": "posterior", + "version": "1.0.0", + "description": "Backend for the Alcoding Web portal", + "main": "app.js", + "scripts": { + "start:dev": "nodemon", + "build": "rimraf ./build && tsc", + "start": "npm run build && node build/app.js", + "lint": "eslint . --ext .ts", + "lint-and-fix": "eslint . --ext .ts --fix", + "prettier-format": "prettier --config .prettierrc src/**/*.ts --write", + "prettier-watch": "onchange src/**/*.ts -- prettier --write {{changed}}" + }, + "husky": { + "hooks": { + "pre-commit": "npm run prettier-format && npm run lint" + } + }, + "repository": { + "type": "git", + "url": "git+https://github.com/pes-alcoding-club/posterior.git" + }, + "keywords": [ + "alcoding", + "backend" + ], + "author": "pes-alcoding-club", + "license": "ISC", + "bugs": { + "url": "https://github.com/pes-alcoding-club/posterior/issues" + }, + "homepage": "https://github.com/pes-alcoding-club/posterior#readme", + "dependencies": { + "express": "^4.17.1", + "jsonwebtoken": "^8.5.1", + "mongoose": "^5.9.22", + "passport": "^0.4.1", + "passport-jwt": "^4.0.0", + "passport-local": "^1.0.0", + "passport-local-mongoose": "^6.0.1" + }, + "devDependencies": { + "@types/express": "^4.17.7", + "@types/mongoose": "^5.7.31", + "@types/node": "^14.0.22", + "@types/passport": "^1.0.4", + "@types/passport-jwt": "^3.0.3", + "@types/passport-local": "^1.0.33", + "@types/passport-local-mongoose": "^4.0.13", + "@typescript-eslint/eslint-plugin": "^3.6.0", + "@typescript-eslint/parser": "^3.6.0", + "eslint": "^7.4.0", + "husky": "^4.2.5", + "nodemon": "^2.0.4", + "onchange": "^7.0.2", + "prettier": "^2.0.5", + "rimraf": "^3.0.2", + "ts-node": "^8.10.2", + "typescript": "^3.9.6" + } }