mirror of
https://github.com/nuxt/nuxt.git
synced 2024-11-11 08:33:53 +00:00
afcaaff57d
Co-authored-by: Daniel Roe <daniel@roe.dev> Co-authored-by: Pooya Parsa <pyapar@gmail.com>
31 lines
531 B
Vue
31 lines
531 B
Vue
<template>
|
|
<div class="app">
|
|
<img src="~/assets/logo.svg" class="h-20 mb-4">
|
|
<h1 class="greeting">
|
|
{{ hello }}, <br>Nuxt 3!
|
|
</h1>
|
|
</div>
|
|
</template>
|
|
|
|
<script setup>
|
|
const greetings = [
|
|
'Hello',
|
|
'Hi',
|
|
'Salut',
|
|
'こんにちは',
|
|
'你好'
|
|
]
|
|
const hello = useState('hello', () => greetings[Math.random() * greetings.length | 0])
|
|
</script>
|
|
|
|
<style scoped>
|
|
.app {
|
|
font-family: Avenir, Helvetica, Arial, sans-serif;
|
|
padding: 1rem 1.5rem;
|
|
}
|
|
.greeting {
|
|
font-size: 4em;
|
|
font-weight: 400;
|
|
}
|
|
</style>
|