Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.
return function(offset: number) {
const lineChar = ts.getLineAndCharacterOfPosition(src, offset);
return {
offset: offset - offsetPrefix,
line: lineChar.line - linePrefix,
character: lineChar.character - charPrefix
};
};
}