platform/video.videojs/dist/video.es.js
function createTrackHelper(self, kind, label, language) {
  var options = arguments.length > 4 && arguments[4] !== undefined ? arguments[4] : {};

  var tracks = self.textTracks();

  options.kind = kind;

  if (label) {
    options.label = label;
  }
  if (language) {
    options.language = language;
  }
  options.tech = self;

  var track = new ALL.text.TrackClass(options);

  tracks.addTrack(track);

  return track;
}
function createTrackHelper(self, kind, label, language) {
  var options = arguments.length > 4 && arguments[4] !== undefined ? arguments[4] : {};

  var tracks = self.textTracks();

  options.kind = kind;

  if (label) {
    options.label = label;
  }
  if (language) {
    options.language = language;
  }
  options.tech = self;

  var track = new ALL.text.TrackClass(options);

  tracks.addTrack(track);

  return track;
}
An Object containing a structure like: `{src: 'url', type: 'mimetype'}` or string
that just contains the src url alone.
* `var SourceObject = {src: 'http://ex.com/video.mp4', type: 'video/mp4'};`
`var SourceString = 'http://example.com/some-video.mp4';`

@typedef {Object|string} Tech~SourceObject

@property {string} src
The url to the source

@property {string} type
The mime type of the source
 
A function used by {@link Tech} to create a new {@link TextTrack}.

@private

@param {Tech} self
An instance of the Tech class.

@param {string} kind
`TextTrack` kind (subtitles, captions, descriptions, chapters, or metadata)

@param {string} [label]
Label to identify the text track

@param {string} [language]
Two letter language abbreviation

@param {Object} [options={}]
An object with additional text track options

@return {TextTrack}
The text track that was created.