I want to show some country flags with this plugin (https://www.growthbunker.dev/vueflags/)
The folder with flags is in:
.app/
../assets/flags <- HERE
../components
../layouts
.. etc
Plugin settings
// plugins/vueflags.js
import Vue from "vue";
import VueFlags from "@growthbunker/vueflags";
Vue.use(VueFlags, {
// Specify the path of the folder where the flags are stored.
iconPath: 'assets/flags',
});
finally i call the component (french's flag should be rendered)
<gb-flag code="fr" size="small" />
But i get this error
GET http://localhost:3000/assets/flags/fr.svg 404 (Not Found)
I tried with iconPath: '~/assets/flags', same error:
GET http://localhost:3000/~/assets/flags/fr.svg 404 (Not Found)
in nuxt.config.js:
buildModules: [
[
"@nuxtjs/vuetify",
{
/* module options */
},
],
["@nuxtjs/svg"],
],