title: VueJS - Function to display image
body: <p>I'm new to VueJS and having a hard to on this situation.</p>
  
  <p><em>display.vue</em></p>
  
  <pre><code>&lt;template&gt;
     &lt;img :src="getLogo(logo)" /&gt; 
  &lt;/template&gt;
  
  &lt;script&gt;
   export default {
    methods: {
      getLogo(logo){
          return '../assets/'+logo;
      }
    }
  }
  &lt;/script&gt;
  </code></pre>
  
  <p>I got an 404 error on that code.</p>
  
  <p>But I tried not using the <code>getLogo()</code> function and it displayed.</p>
  
  <pre><code>&lt;template&gt;
     &lt;img src="../assets/logo.svg" /&gt; 
  &lt;/template&gt;
  </code></pre>
  
  <p>The image structure is:</p>
  
  <pre><code>src/assets/logo1.svg
  </code></pre>
  
  <p><em>webpack.base.conf.js</em></p>
  
  <pre><code>test: /\.(png|jpe?g|gif|svg)(\?.*)?$/,
  loader: 'url-loader',
  options: {
   limit: 10000,
   name: utils.assetsPath('img/[name].[hash:7].[ext]')
  }
  </code></pre>
  
  <p>Anybody here can help me displaying the image by using the <code>getLogo</code> function? Thank you very much!</p>