title: Why does the axios.post return POST 404 (Not Found) error even when axios.get does return a valid value?
body: <p>I'm trying to implement a Vue method called "newKweet" which involves <code>axios</code>, whose purpose is to post a new JSON object to the existing JSON file. </p>
  
  <p>When this method is called, it returns the error <code>POST http://localhost:8080/feed.json 404 (Not Found)</code>, which implies that I'm trying to reach a destination that doesn't exist. </p>
  
  <p>But I find it weird, because when I call <code>axios.get</code> for the same address it works perfectly fine and it retrieves the JSON data stored in the file <code>feed.json</code>. </p>
  
  <p>Can anybody tell me why this is happening, and how to fix it? </p>
  
  <p>The following is how the <code>newKweet()</code> method is defined. </p>
  
  <pre><code>newKweet(){
    var self = this;
    alert(self.kweetInput); 
  
    this.axios.post('/feed.json', {
            avatar: self.userJSON.avatar,
            username: self.userJSON.username,
            handle: self.userJSON.handle,
            timestamp: self.userJSON.timestamp,
            content: self.userJSON.content,
            media: {
              type: self.userJSON.media.type,
              url: self.userJSON.media.url
            },
            actions: {
              replies: self.userJSON.actions.replies,
              rekweets: self.userJSON.actions.rekweets,
              likes: self.userJSON.actions.likes
            }  
        })
        .then(function(response){
          console.log('The output: ');
          console.log(response.data);
        })
        .catch(function(error){
          console.log('An error occured...');
          console.log(error);
        });    
  
        self.kweetInput = '';
        console.log('The end of newKweet() method');
      } 
  </code></pre>
  
  <p>When I replace the <code>post</code> with <code>get</code> in the code above, it properly gets the JSON data stored in the file, which means that <code>axios</code> itself is working, and the address is correct. </p>
  
  <p><strong>[UPDATE]</strong></p>
  
  <p><strong>[The working directory and its contents]</strong></p>
  
  <pre><code>slutuppgift/
  |--                         Static files
  |-- index.html              HTML-code 
  |-- feed.json               the API JSON-data
  |-- src/                
  |-- |-- main.js             JavaScript-code to initialize Vue &amp; app.vue
  |-- |-- App.vue             Vue-code for the application
  |-- |-- components/         Vue-code for components
  |-- |-- views/              Vue-code for pages/templates (Vue-router).
  |-- |-- router.js           JavaScript-code for Vue-router (URL-structure)
  |-- |-- api.js              JavaScript-code for Express.js (the API)
  </code></pre>
  
  <p><strong>[When I open another tab and enter the URL '<a href="http://localhost:8080/feed.json" rel="nofollow noreferrer">http://localhost:8080/feed.json</a>']</strong></p>
  
  <pre><code>[
    {
      "avatar": "/avatar/dankotaru_ketsui.jpeg",
      "username": "安西先生",
      "handle": "@ホッホッホッホ",
      "timestamp": 9031851080000,
      "content": "最後まで希望を捨てちゃいかん。諦めたら、そこで試合終了だよ。…………聞こえんのか？あ？…………私だけかね？まだ勝てると思ってるのは…。",
      "actions": {
        "replies": 35,
        "rekweets": 2700,
        "likes": 5700
      }
    },
    {
      "avatar": "/avatar/makoto_CCO.jfif",
      "username": "誠☆CCO",
      "handle": "@シャアーーーー！！！！",
      "timestamp": 7028851080000,
      "content": "許せカツヲ。胃もたれ的にカレーライスパウダー。ゆうべのロース、売れんかいな！で松屋の天ぷら～のバラけてる身～ね、そう、タラコサラダでビクトーリア☆",
      "actions": {
        "replies": 4,
        "rekweets": 28,
        "likes": 171
      }
    }
  
  .....................
  .....................
  .....................
  
  ]
  </code></pre>