课程: React: Creating and Hosting a Full-Stack Site
免费学习该课程!
今天就开通帐号,24,700 门业界名师课程任您挑!
Why MongoDB?
- [Instructor] All right, at this point, we have a pretty fully functional front-end and back-end for our blog site, so the next thing that we're going to need to do is persist our data. And for our application, it makes sense to persist our data in a database that plays very nicely with JavaScript. And for that, we need look no further than MongoDB. Now, MongoDB is what we call a non-relational database, which means that we can basically just push data into it from our JavaScript code without worrying too much about how that data is formatted. Now, in the case of MongoDB, we can basically just hand our database any kind of JSON object that we want it to store, and we can retrieve them later whenever we need them. Now, this is in contrast to traditional relational databases where the structure of the data in the fields it contains have to generally be defined in advance and adhere to whenever we add new data. Now, working with relational databases also generally requires some…