<ruby id="bdb3f"></ruby>

    <p id="bdb3f"><cite id="bdb3f"></cite></p>

      <p id="bdb3f"><cite id="bdb3f"><th id="bdb3f"></th></cite></p><p id="bdb3f"></p>
        <p id="bdb3f"><cite id="bdb3f"></cite></p>

          <pre id="bdb3f"></pre>
          <pre id="bdb3f"><del id="bdb3f"><thead id="bdb3f"></thead></del></pre>

          <ruby id="bdb3f"><mark id="bdb3f"></mark></ruby><ruby id="bdb3f"></ruby>
          <pre id="bdb3f"><pre id="bdb3f"><mark id="bdb3f"></mark></pre></pre><output id="bdb3f"></output><p id="bdb3f"></p><p id="bdb3f"></p>

          <pre id="bdb3f"><del id="bdb3f"><progress id="bdb3f"></progress></del></pre>

                <ruby id="bdb3f"></ruby>

                合規國際互聯網加速 OSASE為企業客戶提供高速穩定SD-WAN國際加速解決方案。 廣告
                ## 一、組件插槽使用 組件Button.vue模板 ``` <template> <button type="button"><slot name="content"></slot></button> </template> ``` 引入使用 ``` <template> <Button><span slot="content">確認<span></Button> </template> <script> import Button from '@/components/Button.vue' export default { components: { Button } } </script> ``` ## 二、組件自定義事件 組件Button.vue模板 ``` <template> <button type="button" @click="handle"><slot name="content"></slot></button> </template> <script> export default { methods: { handle() { let listeners = this.$listeners; if(listeners.btnclick) { this.$emit('btnclick') // hello world } } } } </script> ``` 引用使用 ``` <template> <Button @btnclick="word"><span slot="content">確認<span></Button> </template> <script> import Button from '@/components/Button.vue' export default { components: { Button }, methods: { word() { console.log('hello world'); } } } </script> ``` ## 三、組件自定義屬性 自定義的屬性要通過props接入,可以限制類型及使用默認值 ``` <Button title="返回支付" /> ``` ``` <template> <button type="button"> {{ title }} </button> </template> <script> export default { name: 'Button', props: { title: { type: String, default: '' } } } </script> ```
                  <ruby id="bdb3f"></ruby>

                  <p id="bdb3f"><cite id="bdb3f"></cite></p>

                    <p id="bdb3f"><cite id="bdb3f"><th id="bdb3f"></th></cite></p><p id="bdb3f"></p>
                      <p id="bdb3f"><cite id="bdb3f"></cite></p>

                        <pre id="bdb3f"></pre>
                        <pre id="bdb3f"><del id="bdb3f"><thead id="bdb3f"></thead></del></pre>

                        <ruby id="bdb3f"><mark id="bdb3f"></mark></ruby><ruby id="bdb3f"></ruby>
                        <pre id="bdb3f"><pre id="bdb3f"><mark id="bdb3f"></mark></pre></pre><output id="bdb3f"></output><p id="bdb3f"></p><p id="bdb3f"></p>

                        <pre id="bdb3f"><del id="bdb3f"><progress id="bdb3f"></progress></del></pre>

                              <ruby id="bdb3f"></ruby>

                              哎呀哎呀视频在线观看