Mongodb – CORS policy: No 'Access-Control-Allow-Origin'
Im develop a react website with node js backend than react show some error link enter image description here
Im develop a react website with node js backend than react show some error link enter image description here
How do i decrease stock in my react app by a delivery button which is connected in MongoDB
I have to update a quantity of product. I have update the data in database using put request but in UI the page need to reload to see the updated value. Here is my code const ItemDetail = () =>…
I am currently building a drawing app using React, Node and MongoDB. It saves images along with name and username in the database. When home page is opened, it has to retrieve and display the image on the screen. The…
I have this type of data on my server. [ { "brand": "Hyundai", "model": "Pickup -0395", "price": 80000 }, { "brand": "Hyundai", "model": "Sports Car -0305", "price": 70000 }, { "brand": "Tesla", "model": "Sports Car -05", "price": 180000 }, {…
app.put('/product/:id', async(req, res) =>{ const id = req.params.id; const updateQuantity = req.body; const filter = {_id: ObjectId(id)}; const options = { upsert: true}; const updateDoc = { $set: { productQuantity: updateQuantity.productQuantity } }; const result = await productCollection.updateOne(filter, updateDoc, options);…
I am trying to update a value in the UI. When I click to update, I have a button that will decrease by one In the database and be displayed in the UI's quantity section. when I click on the…
I have a question about cors implementation in django. Having a problem with setting the correct cors values. My deployment is on docker. I have a deployed 3 containers: backend: Django + DRF as backend (expose 8000 port) Nginx to…
I am new in backend development with MongoDB, NodeJS and frontend development with React-JS. I wanted to make an API endpoint that find the data from MongoDB and filter by user email address when user logged in the system. My…
I've got an React app, which calls internally: /api/* actions. In my case these actions are satisfied by NginX which loads relevant back-end code and returns JSON response. I would like this React app to be "self-served", I would like…