localhost:8080 에서 axios.post('http://localhost:3000/add', {보낼 데이터}
).then((result)=>{
console.log(result)
}) 이렇게 하고
loacalhost:3000 서버에
app.post('/add', (req,res)=>{
res.send('전송완료')
})
이렇게 했을때 각각
GET http://localhost:8080/undefined 404
POST http://localhost:8080/add 404 (Not Found) 이렇게 나오는데 왜 이렇게 되는지 잘 모르겠습니다.
loacalhost:3000 서버에 post요청을 보냈을때 전송완료라는 것이 나와야하는데 나오지가 않네요
Cannot POST /add 이런것만 나옵니다.