webpack Assets
Use the assets folder to add css, images and fonts to your application
In this example:
pages/index.vue shows:
- how to add an image from the assets folder.
- how to add a background image from the assets folder using CSS.
- how to add dynamic images from the assets folder using the data property.
nuxt.config.js contains the css property for globally adding a css file.
assets/main.css shows how to reference the DMSans fonts from the assets folder using the @font-face rule.
Learn more in the Directory Structure book in the Assets chapter.
Loading Sandbox...
Edit this page on GitHub
Updated at Mon, Jul 12, 2021