运行 ❯
获取你
自己的
网站
×
更改方向
保存代码
更改主题,深色/浅色
前往 Spaces
<!DOCTYPE html> <html> <head> <title>Vue v-cloak Directive</title> <style> [v-cloak] { display: none; } #app { padding: 10px; font-size: x-large; background-color: lightgreen; } </style> </head> <body> <h1>Vue v-cloak Example</h1> <p>The v-cloak directive is used to hide the message until compilation is complete.</p> <div id="app" v-cloak> {{ message }} </div> <script src="https://unpkg.com/vue@3/dist/vue.global.js"></script> <script> const app = Vue.createApp({ data() { return { message: "Hello World!" } } }) app.mount('#app') </script> </body> </html>