add function

add(line, curData, scope, docMap)

Tag.add for @constructor. Sets this.type to "constructor".

Also sets this.name and this.title using bit-docs-type-annotate.

Parameters

  1. line {String}:

    Text from @constructor until the end of line.

    For example:

    @constructor my-project/lib/index
    
  2. curData {DocObject}:

    DocObject for the block.

    For example:

    {
      src: {
        path: 'lib/index.js'
      },
      body: '',
      description: '',
      parent: 'my-project/lib'
    }
    
  3. scope {DocObject}:

    DocObject representing current scope.

    For example:

    {
      type: 'script',
      name: 'lib/index.js'
    }
    
  4. docMap {DocMap}:

    DocMap being added to.

Returns

{ProcessTagsCommand}:

['scope', this].