Skip to content

Commit 1ec90db

Browse files
committed
refactor(sfc-playground): add vapor name
1 parent 6958051 commit 1ec90db

File tree

3 files changed

+7
-4
lines changed

3 files changed

+7
-4
lines changed

packages/sfc-playground/index.html

+1-1
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@
55
<meta http-equiv="X-UA-Compatible" content="IE=edge" />
66
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
77
<link rel="icon" type="image/svg" href="/logo.svg" />
8-
<title>Vue SFC Playground</title>
8+
<title>Vue Vapor SFC Playground</title>
99
<script>
1010
const savedPreferDark = localStorage.getItem('vue-sfc-playground-prefer-dark')
1111
if (

packages/sfc-playground/src/Header.vue

+1-1
Original file line numberDiff line numberDiff line change
@@ -68,7 +68,7 @@ function toggleDark() {
6868
<nav>
6969
<h1>
7070
<img alt="logo" src="/logo.svg" />
71-
<span>Vue SFC Playground</span>
71+
<span>Vue Vapor SFC Playground</span>
7272
</h1>
7373
<div class="links">
7474
<VersionSelect
+5-2
Original file line numberDiff line numberDiff line change
@@ -1,12 +1,15 @@
1-
<script setup>
1+
<script setup lang="ts">
22
import { ref, getCurrentInstance } from 'vue'
33
44
const msg = ref('Hello World!')
5+
// @ts-expect-error
56
const isVapor = getCurrentInstance().vapor
67
</script>
78

89
<template>
910
<h1>{{ msg }}</h1>
11+
<p>
12+
VAPOR <b>{{ isVapor ? 'ON' : 'OFF' }}</b>
13+
</p>
1014
<input v-model="msg" />
11-
<b>VAPOR {{ isVapor ? 'ON' : 'OFF' }}</b>
1215
</template>

0 commit comments

Comments
 (0)