Vue navbar image

Hi I want to add a logo image to the navbar in vue application. I placed the logo image in src/assets and added code to home.vue like this:

<f7-nav-left><img src="../assets/logo.png"></f7-nav-left>

But image not shown.

@Yusuf - your code isn’t displaying. Could you repost.

  1. Is there any errors in terminal (during build) in web pack process
  2. Inspect the place where it has to be with browser dev tools to see what is actually there

Hi Vladimir.
1- There is no any error in terminal
2- I inspected the image with chrome dev tools an I saw this line:
<img src="[object Module]">

Why this image is seen as an object?

Try to change webpack config url-loader for images:

Change this:

{
        test: /\.(png|jpe?g|gif|svg)(\?.*)?$/,
        loader: 'url-loader',
        options: {
          limit: 10000,
          name: 'images/[name].[ext]',
        },
      },

to this:

{
        test: /\.(png|jpe?g|gif|svg)(\?.*)?$/,
        loader: 'url-loader',
        options: {
          limit: 10000,
          name: 'images/[name].[ext]',
          esModule: false,
        },
      },