function jsToAst(js) {
  const ast = acorn.parse(js, {
    plugins: { jsx: true },
  });
  if (ast.body.length === 0) throw new Error('Empty AST input');
  return ast;
}
Helper function to convert Javascript stringified code to an AST using acorn-jsx library
@param js