You need to import d3-tip as imported d3 js. I assume you installed d3-tip correctly.
import * as d3 from 'd3'; import d3Tip from "d3-tip";
Then you can use it as below:
var tip = d3Tip().attr('class', 'd3-tip').offset([-12,0]) .html(function(d) { });
This should fix your problem.
source share