Maiquu / nuxt-quasar

Quasar Module for Nuxt (Unofficial)
MIT License
160 stars 9 forks source link

💡 [REQUEST] - Allow to have multiple icon sets specified #97

Closed Xkonti closed 3 months ago

Xkonti commented 3 months ago

Describe the feature

When using Quasar Framework via Quasar CLI, it's possible to have multiple icon sets at the same time. It would be helpful to have the same option in Nuxt.

Additional information

Maiquu commented 3 months ago

Its possible to import mulltiple icon sets via extras.fontIcons at nuxt.config.ts.

export default defineNuxtConfig({
  quasar: {
    extras: {
      fontIcons: [
        // Enter any number of icon set collections you want that comes with `@quasar/extras`
      ]
    }
  }
}

Unless you mean something else, can you provide an example of what you mean.

Xkonti commented 3 months ago

It works! Now I have a config like this:

quasar: {
  plugins: ["Dialog", "Loading", "LoadingBar", "Notify", "Dark"],
  extras: {
    font: "roboto-font",
    fontIcons: ["mdi-v7"],
  },
},

With this setup I can use both material-icons (enabled by default via iconSet) and mdi-v7 set explicitly in extras.fontIcons. What's the difference between extras.fontIcons vs iconSet then?

Maiquu commented 3 months ago

iconSet is the icon set used by quasar components. (Like QEditor, QDate, QColorPicker)

extras.fontIcons simply imports font icon sets so you can use them with QIcon or any of the components with a icon prop.

Xkonti commented 3 months ago

Thanks @Maiquu . This makes it clear :)