• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1"use strict";
2
3exports.parse = function(code, options) {
4  return exports.parseForESLint(code, options).ast;
5};
6
7exports.parseForESLint = function(code, options) {
8  options = options || {};
9  options.ecmaVersion = options.ecmaVersion || 2018;
10  options.sourceType = options.sourceType || "module";
11  options.allowImportExportEverywhere =
12    options.allowImportExportEverywhere || false;
13
14  return require("./parse-with-scope")(code, options);
15};
16
17exports.parseNoPatch = function(code, options) {
18  return require("./parse")(code, options);
19};
20