React to app updates.
Respond to new versions of your application.
Install the module to your Nuxt application with one command:
npx nuxi module add @nasontech/nuxt-update-available
That's it! You can now use useUpdateAvailable()
in your Nuxt app ✨
<script setup lang="ts">
const { updateAvailable } = useUpdateAvailable()
</script>
<template>
<div>
<NuxtRouteAnnouncer />
<NuxtLayout>
<NuxtPage />
</NuxtLayout>
<ClientOnly>
<UpdateDialog :open="updateAvailable" />
</ClientOnly>
</div>
</template>
Local development
# Install dependencies
npm install
# Generate type stubs
npm run dev:prepare
# Develop with the playground
npm run dev
# Build the playground
npm run dev:build
# Run ESLint
npm run lint
# Run Vitest
npm run test
npm run test:watch
# Release new version
npm run release