SOURCE

console 命令行工具 X clear

                    
>
console
const { createApp } = PetiteVue
const { log, dir, table, clear, warn, error } = console; clear();

createApp({
    count: 0,
    num: 0,
    random() {
        this.num = Math.random() * 10000
    },
    mounted() {
        setInterval(()=>{
            this.count++
        }, 1500)
    }
})
.mount()
<div id="app" @vue:mounted="mounted">
    <p>{{count}}</p>
    <button @click="count++">Plus</button>
    <div style="width:fit-content;color:#fff;padding:50px;margin:10px;background:#08f;">
        <span v-effect="random(count)">{{num}}</span>
    </div>
</div>

本项目引用的自定义外部资源