Files
node/tools/node_modules/@babel/plugin-syntax-import-assertions/src/index.js
T
Antoine du Hamel abf3b84d77 tools: add support for import assertions in linter
PR-URL: https://github.com/nodejs/node/pull/39924
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Bradley Farias <bradley.meck@gmail.com>
Reviewed-By: Daijiro Wachi <daijiro.wachi@gmail.com>
Reviewed-By: Rich Trott <rtrott@gmail.com>
Reviewed-By: Zijian Liu <lxxyxzj@gmail.com>

Reviewed-By: Michaël Zasso <targos@protonmail.com>
Reviewed-By: Geoffrey Booth <webadmin@geoffreybooth.com>
2021-11-04 13:19:23 +01:00

14 lines
273 B
JavaScript

import { declare } from "@babel/helper-plugin-utils";
export default declare(api => {
api.assertVersion(7);
return {
name: "syntax-import-assertions",
manipulateOptions(opts, parserOpts) {
parserOpts.plugins.push(["importAssertions"]);
},
};
});