企业🤖AI Agent构建引擎,智能编排和调试,一键部署,支持私有化部署方案 广告
[TOC] ## Popup - 在项目根目录创建 `popup.vue` 或 `popup/indev.vue` ,plasmo会自动识别为 popup页面 - 调试等信息如`console.log`可在插件右键的`弹出审查元素`中查看 示例 /popup.vue ``` <template> <div> <h2 class="text-center"> Welcome to your <a href="https://www.plasmo.com" target="_blank">Plasmo</a> Extension! </h2> <div class="container"> <button @click="decrement">-</button> <p> <b>{{ count }}</b> </p> <button @click="increment">+</button> </div> </div> <p v-if="action" class="action text-center"> {{ action }} </p> <a href="https://www.plasmo.com" target="_blank">123</a> </template> <script > export default { data() { return { count: 0, action: null } }, methods: { increment() { this.count++ }, decrement() { this.count-- this.action = "decrement" }, } } </script> <style> .container { min-width: 470px; display: flex; align-items: center; justify-content: center; gap: 47px; } .text-center { text-align: center; } .action { color: #470; font-weight: bold; } </style> ```