node_modules/echarts/lib/component/tooltip/TooltipView.js
/**
 * From top to bottom. (the last one should be globalTooltipModel);
 */
From top to bottom. (the last one should be globalTooltipModel).
From top to bottom . ( the last one should be globalTooltipModel ) .
function buildTooltipModel(modelCascade, globalTooltipModel, defaultTooltipOption) {
  var ecModel = globalTooltipModel.ecModel;
  var resultModel;
  if (defaultTooltipOption) {
    resultModel = new Model(defaultTooltipOption, ecModel, ecModel);
    resultModel = new Model(globalTooltipModel.option, resultModel, ecModel);
  } else {
    resultModel = globalTooltipModel;
  }
  for (var i = modelCascade.length - 1; i >= 0; i--) {
    var tooltipOpt = modelCascade[i];
    if (tooltipOpt) {
      if (tooltipOpt instanceof Model) {
        tooltipOpt = tooltipOpt.get('tooltip', true);
      } 
      if (isString(tooltipOpt)) {
        tooltipOpt = {
          formatter: tooltipOpt
        };
      }
      if (tooltipOpt) {
        resultModel = new Model(tooltipOpt, resultModel, ecModel);
      }
    }
  }
  return resultModel;
}
function buildTooltipModel ( modelCascade , globalTooltipModel , defaultTooltipOption ) { var ecModel = globalTooltipModel . ecModel ; var resultModel ; if ( defaultTooltipOption ) { resultModel = new Model ( defaultTooltipOption , ecModel , ecModel ) ; resultModel = new Model ( globalTooltipModel . option , resultModel , ecModel ) ; } else { resultModel = globalTooltipModel ; } for ( var i = modelCascade . length - 1 ; i >= 0 ; i -- ) { var tooltipOpt = modelCascade [ i ] ; if ( tooltipOpt ) { if ( tooltipOpt instanceof Model ) { tooltipOpt = tooltipOpt . get ( 'tooltip' , true ) ; } if ( isString ( tooltipOpt ) ) { tooltipOpt = { formatter : tooltipOpt } ; } if ( tooltipOpt ) { resultModel = new Model ( tooltipOpt , resultModel , ecModel ) ; } } } return resultModel ; }
From top to bottom.
From top to bottom .
// Last is always tooltip model. // In each data item tooltip can be simply write: // { //  value: 10, //  tooltip: 'Something you need to know' // }