일 | 월 | 화 | 수 | 목 | 금 | 토 |
---|---|---|---|---|---|---|
1 | 2 | 3 | 4 | 5 | ||
6 | 7 | 8 | 9 | 10 | 11 | 12 |
13 | 14 | 15 | 16 | 17 | 18 | 19 |
20 | 21 | 22 | 23 | 24 | 25 | 26 |
27 | 28 | 29 | 30 |
Tags
- 다중 서버 명령
- node
- MEAN stack
- centos
- event-driven
- API테스트
- Setup
- memory structure
- iIntelliJ
- react-native
- pbkdf2-password
- Linux
- Android
- Mongoose
- multidex
- rest-assured
- Express
- PBKDF2
- ssh key
- Mongo
- window
- MaridDB
- OOP
- instance
- Modulization
- 64k method
- Java
- proguard
- elemMatch
- Git
Archives
- Today
- Total
목록Rest (1)
천줄코딩도 한 걸음부터
MongoDB를 통해 Node.js에서 간단한 REST API 구현
1. Model을 만든다.(=DTO or VO) models/user.jsmodels/user.js var mongoose = require('mongoose'); var Schema = mongoose.Schema; var userSchema = new Schema({ email: String, passwd: String, created_date: {type: Date, default: Date.now()} }); module.exports = mongoose.model('user', userSchema); 2.라우팅 파일 수정 routes/index.js routes/index.js 파일에 만들었던 User Model을 추가한다. 구현한 기능은 3가지 입니다. (1) POST /registMongoD..
Others
2017. 7. 6. 13:03