How to use the @material/tab-bar.MDCTabBar.attachTo function in @material/tab-bar

To help you get started, we’ve selected a few @material/tab-bar examples, based on popular ways it is used in public projects.

Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.

github matsp / material-components-vue / components / tabs / TabBar.vue View on Github external
mounted () {
    this.updateSlot()
    this.mdcTabBar = MDCTabBar.attachTo(this.$el)

    this.slotObserver = new MutationObserver(() => this.updateSlot())
    this.slotObserver.observe(this.$el, {
      childList: true,
      subtree: true
    })
  },
  beforeDestroy () {
github matsp / material-components-vue / components / tabs / TabBar.vue View on Github external
this.$nextTick(() => {
        this.mdcTabBar = MDCTabBar.attachTo(this.$el)
        this.mdcTabBar.focusOnActivate = this.focusOnActivate
        this.mdcTabBar.useAutomaticActivation = this.useAutomaticActivation
      })
    },