extends

extends

1.0.22+

  • Type: Object | Function

  • Details:

    Allows declaratively extending another component (could be either a plain options object or a constructor) without having to use Vue.extend. This is primarily intended to make it easier to extend between single file components.

    This is similar to mixins, the difference being that the component’s own options takes higher priority than the source component being extended.

  • Example:

    var CompA = { ... }
    
    // extend CompA without having to call Vue.extend on either
    var CompB = {
      extends: CompA,
      ...
    }
doc_VueJS
2016-09-25 05:48:07
Comments
Leave a Comment

Please login to continue.