Sébastien Chopin
Co-founder and CTO of NuxtLabs.
November edition
// nuxt.config.js
export default {
target: 'static'
}
nuxt generate
Skip webpack build step when no code has been changed
3.6x times faster re-deploy 🚀
October 2020
Global
Discover websites made with Vue.js
2 months later
Internal changes
The entry point of your Nuxt app
<template>
<h1>Hello Nuxt 3</h1>
</template>
A powerful routing system based on Vue Router 4
How to fetch data with Nuxt 3
import { useFetch } from '@nuxt/composables'
export default {
async setup() {
const $fetch = useFetch()
// Make an API call
const { data: mountains } = await $fetch('https://api.nuxtjs.dev/mountains')
return { mountains }
}
}
// Signature
$fetch(request, options)
// Watch a param
$fetch(() => `https://api.nuxtjs.dev/mountains/${props.slug}`)
// Use a custom fetcher
$fetch(() => $prismic.api.getByUID('page', props.uid))
// Don't block client-side navigation
$fetch('https://api.nuxtjs.dev/mountains', { defer: true })
// Fetch only on client
$fetch('https://api.nuxtjs.dev/mountains', { server: false })
What are the other changes
Learn Nuxt.js Through a Real World App
By Sébastien Chopin
Sébastien Chopin, creator of Nuxt.js will explain the current state of Nuxt 2, the roadmap for Nuxt 3 and what to expect.