250x250
Notice
Recent Posts
Recent Comments
- Today
- Total
일 | 월 | 화 | 수 | 목 | 금 | 토 |
---|---|---|---|---|---|---|
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 | 31 |
Tags
- https
- TailwindCSS
- AWS
- findByIdAndDelete
- clipBehavior
- EC2
- MYSQL
- mongodb
- RDS
- Express
- wil
- await
- certbot
- single quote
- til
- sequelize
- double quote
- Node.js
- Nodejs
- JavaScript
- nginx
- moment
- TypeScript
- atlas
- mongoose
- css
- jsonwebtoken
- Find
- async
- flutter
Link
Archives
반응형
목록create (1)
기억 휘발 방지소
[Node.js / mongoose] mongoDB에 저장을 해보자
데이터를 저장하는 방법에는 두 가지 방법이 있다. save() create() 📌 Document.save() 먼저 자바스크립트 객체를 만들어줘야한다. // Post.js import mongoose from "mongoose"; const postSchema = new mongoose.Schema({ title: String, description: String, createdAt: Date, hashtags: [{ type: String }], meta: { views: Number, rating: Number, }, }); const Post = mongoose.model("Post", postSchema); export default Post; // postController.js import P..
Database/ODM
2021. 9. 20. 16:36
반응형