开发者社区 问答 正文

报告问题context的report函数是怎么使用的?

报告问题context的report函数是怎么使用的?

展开
收起
游客vvhuafakamuxq 2022-05-08 11:16:05 335 分享 版权
来自: 阿里技术
1 条回答
写回答
取消 提交回答
  • function report(reference) { const node = reference.identifier.parent;

    context.report({ node, loc: node.loc, messageId: "unexpected" }); }

    2022-05-08 12:10:12
    赞同 展开评论
问答地址: