packages/cq/dist/index.js
function lineNumberOfCharacterIndex(code, idx) {
  var everythingUpUntilTheIndex = code.substring(0, idx);
  // computer science!
  return everythingUpUntilTheIndex.split("\n").length;
}
function lineNumberOfCharacterIndex(code, idx) {
  var everythingUpUntilTheIndex = code.substring(0, idx);
  // computer science!
  return everythingUpUntilTheIndex.split("\n").length;
}
function lineNumberOfCharacterIndex ( code , idx ) { var everythingUpUntilTheIndex = code . substring ( 0 , idx ) ; // computer science! return everythingUpUntilTheIndex . split ( "\n" ) . length ; }
given character index idx in code, returns the 1-indexed line number
given character index idx in code returns the 1 - indexed line number