Web Dev Academy Meta-frameworks · Nuxt Tool 20 / 64
Meta-frameworks

Nuxt

The Vue meta-framework. File-based routing, server rendering and — its signature trick — auto-imports: use components and composables without ever writing an import.

Demo 01

Auto-imports — write less, ship more

Interactive simulation

In Nuxt you never type import for your components, ref, useFetch or composables — Nuxt scans your folders and wires them in automatically. Click Use it to drop a symbol into the editor and watch the import appear for free.

app.vue — what you write

<script setup>
// no imports needed 🎉
</script>

Nuxt adds behind the scenes

  • import { ref } from 'vue'
  • import { useFetch } from '#app'
  • import TheButton from '~/components/TheButton.vue'

Hover a green symbol in the editor to see where it came from.

<!-- app.vue — zero imports, all auto-wired -->
<script setup>
const count = ref(0)              // ref auto-imported
const { data } = await useFetch('/api/me') // composable auto-imported
</script>
Demo 02

pages/ → routes, automatically

Interactive simulation

Like Next, Nuxt turns the pages/ folder into your router. [id].vue means a dynamic param. Click a file to see its URL and the rendered Vue page.

pages/ directory

  • 📄 index.vue
  • 📄 about.vue
  • 📄 products/index.vue
  • 📄 products/[id].vue
  • 📄 blog/[slug].vue

URL + rendered page

/
rendered .vue
Home

A .vue file in pages/ becomes a route automatically.

Demo 03

Vue reactivity inside Nuxt

Interactive simulation

Nuxt is Vue, so the UI reacts to state instantly. This counter mimics a ref() bound to the template — change the value, the view updates.

count = ref(0)
0
<script setup>
const count = ref(0)
</script>
<template>
  <button @click="count++">{{ count }}</button>
</template>
Demo 04

useFetch — data with one call

Interactive simulation

Nuxt's useFetch handles loading, caching and SSR data hydration in a single composable. Press the button to simulate fetching server data.

// { pending, data, error } appear here
i
Demos are interactive simulations built with vanilla JS — Nuxt runs via a build step / Node server and can't execute inside a static page. The real Nuxt + Vue code is shown in the dark code blocks above.

↑ All 64 tools