Sleep

Nuxt Svgo Loading Machine - Vue.js Supplied #.\n\nNuxt component to load SVG files as Vue components, utilizing SVGO for optimization.\nAttributes.\nLots SVG files as Vue components.\nOptimize SVGs making use of SVGO.\nSmooth combination along with Nuxt DevTools.\nSetup.\nMount and include nuxt-svgo-loader to your nuxt.config.\n

Whichever matches your deal manager.pnpm incorporate -D nuxt-svgo-loader.npm install -D nuxt-svgo-loader.yarn add -D nuxt-svgo-loader.export nonpayment defineNuxtConfig( modules: [' nuxt-svgo-loader'],.svgoLoader: // Options listed below will be actually exchanged 'vite-svg-loader'. ).[TAKE NOTE] Since nuxt-svgo-loader is actually a Nuxt element based on vite-svg-loader, the setup for svgoLoader continues to be the same to that of vite-svg-loader. You may pertain to the documentation of vite-svg-loader for the offered possibilities here.Usage.Component.SVGs can be clearly imported as Vue parts making use of the? component suffix:.bring in NuxtSvg coming from '~/ assets/svg/nuxt. svg'.//.URL.SVGs could be imported as URLs utilizing the? url suffix:.bring in nuxtSvgUrl from '~/ assets/svg/nuxt. svg?url'.// nuxtSvgUrl === '/ _ nuxt/assets/svg/ nuxt.svg'.Raw.SVGs could be imported as fresh cords using the? uncooked suffix:.bring in nuxtSvgRaw coming from '~/ assets/svg/nuxt. svg?raw'.// nuxtSvgRaw === '.

Articles You Can Be Interested In