code: function(element) {
      // use given mask or create a new one
      this.masker = element instanceof SVG.Mask ? element : this.parent().mask().add(element)
  
      // store reverence on self in mask
      this.masker.targets.push(this)
  
      // apply mask
      return this.attr('mask', 'url("#' + this.masker.attr('id') + '")')
    }
docs: Distribute mask to svg element