diff --git a/.circleci/config.yml b/.circleci/config.yml index 30397ea0cede..08e754be050f 100644 --- a/.circleci/config.yml +++ b/.circleci/config.yml @@ -115,7 +115,7 @@ jobs: <<: *test262_workdir - store_artifacts: *artifact_test262_diff_tap - run: - name: Output comparision results and report to CircleCI + name: Output comparison results and report to CircleCI command: | mkdir -p ~/test-results/test262 cat ~/diff.tap | $(npm bin)/tap-merge | $(npm bin)/tap-mocha-reporter xunit | tee ~/test-results/test262/results.xml diff --git a/eslint/babel-eslint-plugin-development/src/utils/get-reference-origin.js b/eslint/babel-eslint-plugin-development/src/utils/get-reference-origin.js index 25fd7b0a541f..ffa90fe2a4e7 100644 --- a/eslint/babel-eslint-plugin-development/src/utils/get-reference-origin.js +++ b/eslint/babel-eslint-plugin-development/src/utils/get-reference-origin.js @@ -21,7 +21,7 @@ type ReferenceOrigin = // Given a node and a context, returns a description of where its value comes // from. // It resolves imports, parameters of exported functions and property accesses. -// See the ReferenceOrigin type for more informations. +// See the ReferenceOrigin type for more information. export default function getReferenceOrigin( node, scope, diff --git a/packages/babel-compat-data/scripts/build-corejs3-proposals.js b/packages/babel-compat-data/scripts/build-corejs3-proposals.js index 80cecb1b36a6..e3b4d867a4f7 100644 --- a/packages/babel-compat-data/scripts/build-corejs3-proposals.js +++ b/packages/babel-compat-data/scripts/build-corejs3-proposals.js @@ -25,10 +25,10 @@ const builtInDefinitionsPath = path.join( const builtInDefinitions = fs.readFileSync(builtInDefinitionsPath, "utf-8"); for (const feature of finishedProposals) { - const standarizedName = feature.replace("esnext.", "es."); - if (!builtInDefinitions.includes(standarizedName)) { + const standardizedName = feature.replace("esnext.", "es."); + if (!builtInDefinitions.includes(standardizedName)) { console.log( - `${feature} is now standarized as ${standarizedName}, please add "${standarizedName}" to "${builtInDefinitionsPath}"` + `${feature} is now standarized as ${standardizedName}, please add "${standardizedName}" to "${builtInDefinitionsPath}"` ); } } diff --git a/packages/babel-core/src/config/files/import.js b/packages/babel-core/src/config/files/import.js index d81b18f7539f..3db10a4e9e1b 100644 --- a/packages/babel-core/src/config/files/import.js +++ b/packages/babel-core/src/config/files/import.js @@ -1,5 +1,5 @@ // @flow -// We keep this in a seprate file so that in older node versions, where +// We keep this in a separate file so that in older node versions, where // import() isn't supported, we can try/catch around the require() call // when loading this file. diff --git a/packages/babel-core/src/gensync-utils/async.js b/packages/babel-core/src/gensync-utils/async.js index a7d70c47bc7c..2b474aeed692 100644 --- a/packages/babel-core/src/gensync-utils/async.js +++ b/packages/babel-core/src/gensync-utils/async.js @@ -10,7 +10,7 @@ const runGenerator = gensync(function* (item) { return yield* item; }); -// This Gensync returns true if the current execution contect is +// This Gensync returns true if the current execution context is // asynchronous, otherwise it returns false. export const isAsync = gensync<[], boolean>({ sync: () => false, diff --git a/packages/babel-helper-module-transforms/src/rewrite-live-references.js b/packages/babel-helper-module-transforms/src/rewrite-live-references.js index f036d578b6ba..6bf4aaad3cb5 100644 --- a/packages/babel-helper-module-transforms/src/rewrite-live-references.js +++ b/packages/babel-helper-module-transforms/src/rewrite-live-references.js @@ -12,7 +12,7 @@ export default function rewriteLiveReferences( const imported = new Map(); const exported = new Map(); const requeueInParent = path => { - // Manualy re-queue `exports.default =` expressions so that the ES3 + // Manually re-queue `exports.default =` expressions so that the ES3 // transform has an opportunity to convert them. Ideally this would // happen automatically from the replaceWith above. See #4140 for // more info. diff --git a/packages/babel-helper-split-export-declaration/src/index.js b/packages/babel-helper-split-export-declaration/src/index.js index c591f8746396..a2eae668e07a 100644 --- a/packages/babel-helper-split-export-declaration/src/index.js +++ b/packages/babel-helper-split-export-declaration/src/index.js @@ -2,7 +2,7 @@ import * as t from "@babel/types"; export default function splitExportDeclaration(exportDeclaration) { if (!exportDeclaration.isExportDeclaration()) { - throw new Error("Only export declarations can be splitted."); + throw new Error("Only export declarations can be split."); } // build specifiers that point back to this export declaration diff --git a/packages/babel-parser/src/plugins/flow.js b/packages/babel-parser/src/plugins/flow.js index 508845d1046c..9e052f4e80fb 100644 --- a/packages/babel-parser/src/plugins/flow.js +++ b/packages/babel-parser/src/plugins/flow.js @@ -1077,7 +1077,7 @@ export default (superClass: Class): Class => /* The inexact flag should only be added on ObjectTypeAnnotations that * are not the body of an interface, declare interface, or declare class. - * Since spreads are only allowed in objec types, checking that is + * Since spreads are only allowed in object types, checking that is * sufficient here. */ if (allowSpread) { @@ -2698,7 +2698,7 @@ export default (superClass: Class): Class => if (!arrow.error && arrowExpression) return arrowExpression; - // If we are here, both JSX and Flow parsing attemps failed. + // If we are here, both JSX and Flow parsing attempts failed. // Give the precedence to the JSX error, except if JSX had an // unrecoverable error while Flow didn't. // If the error is recoverable, we can only re-report it if there is diff --git a/packages/babel-plugin-proposal-object-rest-spread/src/index.js b/packages/babel-plugin-proposal-object-rest-spread/src/index.js index 173dd794f69a..e1f9b7d51016 100644 --- a/packages/babel-plugin-proposal-object-rest-spread/src/index.js +++ b/packages/babel-plugin-proposal-object-rest-spread/src/index.js @@ -596,7 +596,7 @@ export default declare((api, opts) => { exp = t.callExpression(t.cloneNode(helper), [ exp, // If we have static props, we need to insert an empty object - // becuase the odd arguments are copied with [[Get]], not + // because the odd arguments are copied with [[Get]], not // [[GetOwnProperty]] ...(hadProps ? [t.objectExpression([]), obj] : []), ]); diff --git a/packages/babel-plugin-transform-classes/test/fixtures/get-set/call-semantics-not-defined-on-parent/exec.js b/packages/babel-plugin-transform-classes/test/fixtures/get-set/call-semantics-not-defined-on-parent/exec.js index 8ff77f141106..6e826647d0c3 100644 --- a/packages/babel-plugin-transform-classes/test/fixtures/get-set/call-semantics-not-defined-on-parent/exec.js +++ b/packages/babel-plugin-transform-classes/test/fixtures/get-set/call-semantics-not-defined-on-parent/exec.js @@ -16,6 +16,6 @@ const obj = new Obj(); expect(() => { obj.call(); - // Asser that this throws, but that it's not + // Assert that this throws, but that it's not // Obj.p.test's error that is thrown }).toThrowError(TypeError) diff --git a/packages/babel-plugin-transform-classes/test/fixtures/get-set/call-semantics-not-defined-on-parent/input.js b/packages/babel-plugin-transform-classes/test/fixtures/get-set/call-semantics-not-defined-on-parent/input.js index 8ff77f141106..6e826647d0c3 100644 --- a/packages/babel-plugin-transform-classes/test/fixtures/get-set/call-semantics-not-defined-on-parent/input.js +++ b/packages/babel-plugin-transform-classes/test/fixtures/get-set/call-semantics-not-defined-on-parent/input.js @@ -16,6 +16,6 @@ const obj = new Obj(); expect(() => { obj.call(); - // Asser that this throws, but that it's not + // Assert that this throws, but that it's not // Obj.p.test's error that is thrown }).toThrowError(TypeError) diff --git a/packages/babel-plugin-transform-classes/test/fixtures/get-set/call-semantics-not-defined-on-parent/output.js b/packages/babel-plugin-transform-classes/test/fixtures/get-set/call-semantics-not-defined-on-parent/output.js index 02de2a67244b..cac6975c65f6 100644 --- a/packages/babel-plugin-transform-classes/test/fixtures/get-set/call-semantics-not-defined-on-parent/output.js +++ b/packages/babel-plugin-transform-classes/test/fixtures/get-set/call-semantics-not-defined-on-parent/output.js @@ -56,6 +56,6 @@ let Obj = /*#__PURE__*/function (_Base) { const obj = new Obj(); expect(() => { - obj.call(); // Asser that this throws, but that it's not + obj.call(); // Assert that this throws, but that it's not // Obj.p.test's error that is thrown }).toThrowError(TypeError); diff --git a/packages/babel-plugin-transform-classes/test/fixtures/get-set/call-semantics-setter-defined-on-parent/exec.js b/packages/babel-plugin-transform-classes/test/fixtures/get-set/call-semantics-setter-defined-on-parent/exec.js index 184778853f1f..9b74ae7319b7 100644 --- a/packages/babel-plugin-transform-classes/test/fixtures/get-set/call-semantics-setter-defined-on-parent/exec.js +++ b/packages/babel-plugin-transform-classes/test/fixtures/get-set/call-semantics-setter-defined-on-parent/exec.js @@ -19,6 +19,6 @@ const obj = new Obj(); expect(() => { obj.call(); - // Asser that this throws, but that it's not + // Assert that this throws, but that it's not // a gobbledygook error that is thrown }).toThrowError(TypeError) diff --git a/packages/babel-preset-env/CONTRIBUTING.md b/packages/babel-preset-env/CONTRIBUTING.md index b17d1f453b73..53fc57b64b54 100644 --- a/packages/babel-preset-env/CONTRIBUTING.md +++ b/packages/babel-preset-env/CONTRIBUTING.md @@ -51,13 +51,13 @@ const es = { } ``` -If you wan to transform a new built-in by `useBuiltIns: 'usage'`, add mapping to related `core-js` modules to [this file](https://github.com/babel/babel/blob/main/packages/babel-preset-env/polyfills/corejs2/built-in-definitions.js). +If you want to transform a new built-in by `useBuiltIns: 'usage'`, add mapping to related `core-js` modules to [this file](https://github.com/babel/babel/blob/main/packages/babel-preset-env/polyfills/corejs2/built-in-definitions.js). ### Update data for `core-js@3` polyfilling Just update the version of [`core-js-compat`](https://github.com/zloirock/core-js/tree/main/packages/core-js-compat) in dependencies. -If you wan to transform a new built-in by `useBuiltIns: 'usage'`, add mapping to related [`core-js`](https://github.com/zloirock/core-js/tree/main/packages/core-js/modules) modules to [this file](https://github.com/babel/babel/blob/main/packages/babel-preset-env/polyfills/corejs3/built-in-definitions.js). +If you want to transform a new built-in by `useBuiltIns: 'usage'`, add mapping to related [`core-js`](https://github.com/zloirock/core-js/tree/main/packages/core-js/modules) modules to [this file](https://github.com/babel/babel/blob/main/packages/babel-preset-env/polyfills/corejs3/built-in-definitions.js). If you want to mark a new proposal as shipped, add it to [this list](https://github.com/babel/babel/blob/main/packages/babel-preset-env/polyfills/corejs3/shipped-proposals.js). diff --git a/packages/babel-preset-env/src/normalize-options.js b/packages/babel-preset-env/src/normalize-options.js index f86621f5715b..bef9fe27677e 100644 --- a/packages/babel-preset-env/src/normalize-options.js +++ b/packages/babel-preset-env/src/normalize-options.js @@ -33,7 +33,7 @@ const validateTopLevelOptions = (options: Options) => { const allPluginsList = Object.keys(pluginsList); -// NOTE: Since module plugins are handled seperatly compared to other plugins (via the "modules" option) it +// NOTE: Since module plugins are handled separately compared to other plugins (via the "modules" option) it // should only be possible to exclude and not include module plugins, otherwise it's possible that preset-env // will add a module plugin twice. const modulePlugins = [ diff --git a/packages/babel-traverse/src/path/introspection.js b/packages/babel-traverse/src/path/introspection.js index 7060b6a2f51f..c816765c2c0e 100644 --- a/packages/babel-traverse/src/path/introspection.js +++ b/packages/babel-traverse/src/path/introspection.js @@ -402,7 +402,7 @@ export function _guessExecutionStatusRelativeToDifferentFunctions( return "unknown"; } - // Prevent infinte loops in recursive functions + // Prevent infinite loops in recursive functions if (executionOrderCheckedNodes.has(path.node)) continue; executionOrderCheckedNodes.add(path.node); diff --git a/packages/babel-types/src/builders/flow/createFlowUnionType.js b/packages/babel-types/src/builders/flow/createFlowUnionType.js index 30a6f08771d7..2f2dd03ffbc4 100644 --- a/packages/babel-types/src/builders/flow/createFlowUnionType.js +++ b/packages/babel-types/src/builders/flow/createFlowUnionType.js @@ -4,7 +4,7 @@ import removeTypeDuplicates from "../../modifications/flow/removeTypeDuplicates" /** * Takes an array of `types` and flattens them, removing duplicates and - * returns a `UnionTypeAnnotation` node containg them. + * returns a `UnionTypeAnnotation` node containing them. */ export default function createFlowUnionType(types: Array): Object { const flattened = removeTypeDuplicates(types); diff --git a/packages/babel-types/src/builders/typescript/createTSUnionType.js b/packages/babel-types/src/builders/typescript/createTSUnionType.js index 93d52c113f06..ae4e5ded1c2f 100644 --- a/packages/babel-types/src/builders/typescript/createTSUnionType.js +++ b/packages/babel-types/src/builders/typescript/createTSUnionType.js @@ -3,7 +3,7 @@ import removeTypeDuplicates from "../../modifications/typescript/removeTypeDupli /** * Takes an array of `types` and flattens them, removing duplicates and - * returns a `UnionTypeAnnotation` node containg them. + * returns a `UnionTypeAnnotation` node containing them. */ export default function createTSUnionType( typeAnnotations: Array,