Merge remote-tracking branch 'upstream/master' into next

This commit is contained in:
Jed Fox committed 2019-11-10 13:55:55 -05:00
commit 739235fe2b
73 files changed
+2217 -1577

No files matched your search

+1 -1
View File
@@ -26,7 +26,7 @@ Tip! Don't write this stuff manually.
-->
**Prettier 1.18.2**
**Prettier 1.19.1**
[Playground link](https://prettier.io/playground/#.....)
```sh
# Options (if any):
+1 -1
View File
@@ -19,7 +19,7 @@ BEFORE SUBMITTING AN ISSUE:
-->
**Environments:**
- Prettier Version: 1.18.2
- Prettier Version: 1.19.1
- Running Prettier via: <!-- CLI, Node.js API, Browser API, etc. -->
- Runtime: <!-- Node.js v6, Chrome v67, etc. -->
- Operating System: <!-- Windows, Linux, macOS, etc. -->
+1 -1
View File
@@ -5,7 +5,7 @@
- [ ] I’ve added tests to confirm my change works.
- [ ] (If changing the API or CLI) I’ve documented the changes I’ve made (in the `docs/` directory)
- [ ] (If the change is user-facing) I’ve added my changes to the `CHANGELOG.unreleased.md` file following the template.
- [ ] (If the change is user-facing) I’ve added my changes to `changelog_unreleased/*/pr-XXXX.md` file following `changelog_unreleased/TEMPLATE.md`.
- [ ] I’ve read the [contributing guidelines](https://github.com/prettier/prettier/blob/master/CONTRIBUTING.md).
**✨[Try the playground for this PR](https://prettier.io/playground-redirect)✨**
+50
View File
@@ -1,3 +1,53 @@
# 1.19.1
[diff](https://github.com/prettier/prettier/compare/1.19.0...1.19.1)
### CLI
#### Fix `--stdin` regression in 1.19.0 ([#6894](https://github.com/prettier/prettier/pull/6894) by [@lydell](https://github.com/lydell))
<!-- prettier-ignore -->
```
// Prettier stable
$ echo "test" | prettier --stdin --parser babel
[error] regeneratorRuntime is not defined
// Prettier master
$ echo "test" | prettier --stdin --parser babel
test;
```
### TypeScript
#### Fix formatting of union type as arrow function return type ([#6896](https://github.com/prettier/prettier/pull/6896) by [@thorn0](https://github.com/thorn0))
<!-- prettier-ignore -->
```jsx
// Input
export const getVehicleDescriptor = async (
vehicleId: string,
): Promise<Collections.Parts.PrintedCircuitBoardAssembly['attributes'] | undefined> => {}
// Prettier stable
export const getVehicleDescriptor = async (
vehicleId: string
): Promise<| Collections.Parts.PrintedCircuitBoardAssembly["attributes"]
| undefined> => {};
// Prettier master
export const getVehicleDescriptor = async (
vehicleId: string
): Promise<
Collections.Parts.PrintedCircuitBoardAssembly["attributes"] | undefined
> => {};
```
# 1.19.0
[diff](https://github.com/prettier/prettier/compare/1.18.2...1.19.0)
🔗 [Release Notes](https://prettier.io/blog/2019/11/09/1.19.0.html)
# 1.18.2
[diff](https://github.com/prettier/prettier/compare/1.18.1...1.18.2)
+39
View File
@@ -0,0 +1,39 @@
<!--
1. Choose a folder based on which language your PR is for.
- For JavaScript, choose `javascript/` etc.
- For TypeScript specific syntax, choose `typescript/`.
- If your PR applies to multiple languages, such as TypeScript/Flow, choose one folder and mention which languages it applies to.
2. In your chosen folder, create a file with your PR number: `pr-XXXX.md`. For example: `typescript/pr-6728.md`.
3. Copy the content below and paste it in your new file.
4. Fill in a title, the PR number and your user name.
5. Optionally write a description. Many times it’s enough with just sample code.
6. Change ```jsx to your language. For example, ```yaml.
7. Change the `// Input` and `// Prettier` comments to the comment syntax of your language. For example, `# Input`.
8. Choose some nice input example code. Paste it along with the output before and after your PR.
-->
#### Title ([#XXXX](https://github.com/prettier/prettier/pull/XXXX) by [@user](https://github.com/user))
Optional description if it makes sense.
<!-- prettier-ignore -->
```jsx
// Input
(foo ?? baz) || baz;
// Prettier stable
foo ?? baz || baz;
// Prettier master
(foo ?? baz) || baz;
```
Whitespace-only changes.
View File
Whitespace-only changes.
View File
Whitespace-only changes.
View File
Whitespace-only changes.
View File
Whitespace-only changes.
Whitespace-only changes.
Whitespace-only changes.
View File
Whitespace-only changes.
Whitespace-only changes.
View File
Whitespace-only changes.
View File
Whitespace-only changes.
View File
Whitespace-only changes.
Whitespace-only changes.
View File
Whitespace-only changes.
View File
Whitespace-only changes.
Whitespace-only changes.
View File
Whitespace-only changes.
View File
Whitespace-only changes.
+4 -1
View File
@@ -288,6 +288,7 @@
"React's",
"readline",
"readlines",
"rebalance",
"rebeccapurple",
"recurse",
"recurses",
@@ -337,6 +338,7 @@
"superset",
"supertypes",
"swac",
"systemjs",
"tdeekens",
"templating",
"tempy",
@@ -362,6 +364,7 @@
"unparenthesized",
"unparseable",
"unpause",
"unpkg",
"unrestrict",
"untracked",
"valourous",
@@ -396,4 +399,4 @@
"ve{2,}r{2,}y",
"ve+r+y+long\\w*"
]
}
}
+12 -10
View File
@@ -3,7 +3,7 @@ id: browser
title: Browser
---
Run Prettier in the browser with the `standalone.js` UMD bundle shipped in the NPM package (starting in version 1.13). The new UMD bundle only formats the code and has no support for config files, ignore files, CLI usage, or automatic loading of plugins.
Run Prettier in the browser with the `standalone.js` UMD bundle shipped in the NPM package (starting in version 1.13). The UMD bundle only formats the code and has no support for config files, ignore files, CLI usage, or automatic loading of plugins.
### `prettier.format(code, options)`
@@ -15,12 +15,14 @@ See [Usage](#usage) below for examples.
### Global
<!-- prettier-ignore -->
```html
<script src="https://unpkg.com/prettier@1.13.0/standalone.js"></script>
<script src="https://unpkg.com/prettier@1.13.0/parser-graphql.js"></script>
<script type="text/javascript">
prettier.format("query { }", { parser: "graphql", plugins: prettierPlugins });
<script src="https://unpkg.com/prettier@1.19.1/standalone.js"></script>
<script src="https://unpkg.com/prettier@1.19.1/parser-graphql.js"></script>
<script>
prettier.format("query { }", {
parser: "graphql",
plugins: prettierPlugins
});
</script>
```
@@ -40,8 +42,8 @@ prettier.format("query { }", {
```js
define([
"https://unpkg.com/prettier@1.13.0/standalone.js",
"https://unpkg.com/prettier@1.13.0/parser-graphql.js"
"https://unpkg.com/prettier@1.19.1/standalone.js",
"https://unpkg.com/prettier@1.19.1/parser-graphql.js"
], (prettier, ...plugins) => {
prettier.format("query { }", { parser: "graphql", plugins });
});
@@ -60,7 +62,7 @@ This syntax doesn't necessarily work in the browser, but it can be used when bun
### Worker
```js
importScripts("https://unpkg.com/prettier@1.13.0/standalone.js");
importScripts("https://unpkg.com/prettier@1.13.0/parser-graphql.js");
importScripts("https://unpkg.com/prettier@1.19.1/standalone.js");
importScripts("https://unpkg.com/prettier@1.19.1/parser-graphql.js");
prettier.format("query { }", { parser: "graphql", plugins: prettierPlugins });
```
+1 -1
View File
@@ -124,7 +124,7 @@ Then in `tslint.json`:
### Disable formatting rules
[`stylelint-config-prettier`](https://github.com/prettier/stylelint-config-prettier) is a config that disables rules that conflict with Prettier. Add it to your `devDependencies`, then extend from it within your `.stylelintrc` configuration. Make sure to put it last in the `extends` array, so it gets the chance to override other configs.
[`stylelint-config-prettier`](https://github.com/prettier/stylelint-config-prettier) is a config that disables rules that conflict with Prettier. Add it to your [`devDependencies`], then extend from it within your `.stylelintrc` configuration. Make sure to put it last in the `extends` array, so it gets the chance to override other configs.
```bash
yarn add --dev stylelint-config-prettier
+4 -2
View File
@@ -132,9 +132,11 @@ One final thing: TC39 has [not yet decided if decorators come before or after `e
```js
@decorator
export class Foo { }
export class Foo {}
export @decorator class Foo { }
export
@decorator
class Foo {}
```
### Semicolons
+9 -9
View File
@@ -1,6 +1,6 @@
{
"name": "prettier",
"version": "1.18.2",
"version": "1.20.0-dev",
"description": "Prettier is an opinionated code formatter",
"bin": {
"prettier": "./bin/prettier.js"
@@ -16,7 +16,7 @@
"dependencies": {
"@angular/compiler": "8.2.13",
"@babel/code-frame": "7.5.5",
"@babel/parser": "7.7.2",
"@babel/parser": "7.7.3",
"@glimmer/syntax": "0.41.0",
"@iarna/toml": "2.2.3",
"@typescript-eslint/typescript-estree": "2.6.1",
@@ -35,8 +35,8 @@
"esutils": "2.0.3",
"find-parent-dir": "0.3.0",
"find-project-root": "1.1.1",
"flow-parser": "0.111.1",
"get-stream": "5.1.0",
"flow-parser": "0.111.3",
"get-stream": "4.1.0",
"globby": "6.1.0",
"graphql": "14.5.8",
"html-element-attributes": "2.2.0",
@@ -74,14 +74,14 @@
"yaml-unist-parser": "1.1.1"
},
"devDependencies": {
"@babel/core": "7.7.0",
"@babel/core": "7.7.2",
"@babel/preset-env": "7.7.1",
"@rollup/plugin-alias": "2.2.0",
"@rollup/plugin-replace": "2.2.0",
"@rollup/plugin-replace": "2.2.1",
"babel-loader": "8.0.6",
"benchmark": "2.1.4",
"builtin-modules": "3.1.0",
"codecov": "codecov/codecov-node#e427d900309adb50746a39a50aa7d80071a5ddd0",
"codecov": "3.6.1",
"cross-env": "6.0.3",
"eslint": "6.6.0",
"eslint-config-prettier": "6.5.0",
@@ -96,7 +96,7 @@
"jest-snapshot-serializer-raw": "1.1.0",
"jest-watch-typeahead": "0.4.0",
"mkdirp": "0.5.1",
"prettier": "1.18.2",
"prettier": "1.19.1",
"prettylint": "1.0.0",
"rimraf": "3.0.0",
"rollup": "1.26.3",
@@ -130,6 +130,6 @@
"build": "node --max-old-space-size=3072 ./scripts/build/build.js",
"build-docs": "node ./scripts/build-docs.js",
"check-deps": "node ./scripts/check-deps.js",
"spellcheck": "npx -p cspell@4.0.31 cspell {bin,scripts,src}/**/*.js {docs,website/blog}/**/*.md CHANGELOG.unreleased.md"
"spellcheck": "npx -p cspell@4.0.31 cspell {bin,scripts,src}/**/*.js {docs,website/blog,changelog_unreleased}/**/*.md"
}
}
+1 -1
View File
@@ -99,7 +99,7 @@ async function run(params) {
await execa("rm", ["-rf", ".cache"]);
}
const bundleCache = new Cache(".cache/", "v18");
const bundleCache = new Cache(".cache/", "v19");
await bundleCache.load();
console.log(chalk.inverse(" Building packages "));
+10 -9
View File
@@ -6,13 +6,17 @@ const path = require("path");
module.exports = function() {
let banner;
let entry;
let file;
return {
name: "executable",
options(options) {
entry = path.resolve(options.input);
return options;
options(inputOptions) {
entry = path.resolve(inputOptions.input);
},
generateBundle(outputOptions) {
file = outputOptions.file;
},
load(id) {
@@ -36,12 +40,9 @@ module.exports = function() {
}
},
writeBundle(bundle) {
if (banner) {
const files = Object.keys(bundle);
files.forEach(file => {
fs.chmodSync(bundle[file].facadeModuleId, 0o755 & ~process.umask());
});
writeBundle() {
if (banner && file) {
fs.chmodSync(file, 0o755 & ~process.umask());
}
}
};
-2
View File
@@ -3,8 +3,6 @@
## Usage
```sh
# set environment variable GITHUB_API_TOKEN if it's a patch release
# since we need to get merged PRs from GitHub to generate changelog
node ./scripts/release/release.js --version NEW_VERSION
```
+1 -1
View File
@@ -57,7 +57,7 @@ module.exports = async function({ version, previousVersion }) {
dedent(chalk`
{yellow.bold A manual step is necessary.}
You can copy the entries from {bold CHANGELOG.unreleased.md} to {bold CHANGELOG.md}
You can copy the entries from {bold changelog_unreleased/*/pr-*.md} to {bold CHANGELOG.md}
and update it accordingly.
You don't need to commit the file, the script will take care of that.
+5
View File
@@ -16,6 +16,11 @@ async function bump({ version }) {
content.replace(/^(- Prettier Version: ).*?$/m, `$1${version}`)
);
// Update unpkg link in docs
processFile("docs/browser.md", content =>
content.replace(/(\/\/unpkg\.com\/prettier@)(?:.*?)\//g, `$1${version}/`)
);
await execa("yarn", ["update-stable-docs"], {
cwd: "./website"
});
+2 -1
View File
@@ -593,7 +593,8 @@ function genericPrint(path, options, print) {
(isAdditionNode(iNode) || isSubtractionNode(iNode)) &&
i === 0 &&
(iNextNode.type === "value-number" || iNextNode.isHex) &&
(parentParentNode && isColorAdjusterFuncNode(parentParentNode)) &&
parentParentNode &&
isColorAdjusterFuncNode(parentParentNode) &&
!hasEmptyRawBefore(iNextNode);
const requireSpaceBeforeOperator =
+4 -4
View File
@@ -207,10 +207,10 @@ function genericPrint(path, options, print) {
const shouldHugContent =
node.children.length === 1 &&
node.firstChild.type === "interpolation" &&
(node.firstChild.isLeadingSpaceSensitive &&
!node.firstChild.hasLeadingSpaces) &&
(node.lastChild.isTrailingSpaceSensitive &&
!node.lastChild.hasTrailingSpaces);
node.firstChild.isLeadingSpaceSensitive &&
!node.firstChild.hasLeadingSpaces &&
node.lastChild.isTrailingSpaceSensitive &&
!node.lastChild.hasTrailingSpaces;
const attrGroupId = Symbol("element-attr-group-id");
return concat([
group(
+8 -4
View File
@@ -276,9 +276,9 @@ function forceBreakContent(node) {
node.children.some(child => hasNonTextChild(child)))) ||
(node.firstChild &&
node.firstChild === node.lastChild &&
(hasLeadingLineBreak(node.firstChild) &&
(!node.lastChild.isTrailingSpaceSensitive ||
hasTrailingLineBreak(node.lastChild))))
hasLeadingLineBreak(node.firstChild) &&
(!node.lastChild.isTrailingSpaceSensitive ||
hasTrailingLineBreak(node.lastChild)))
);
}
@@ -385,7 +385,11 @@ function inferScriptParser(node) {
}
if (node.name === "style") {
if (!node.attrMap.lang || node.attrMap.lang === "postcss") {
if (
!node.attrMap.lang ||
node.attrMap.lang === "postcss" ||
node.attrMap.lang === "css"
) {
return "css";
}
+33
View File
@@ -37,6 +37,11 @@ function clean(ast, newObj, parent) {
return null;
}
// We remove unneeded parens around same-operator LogicalExpressions
if (isUnbalancedLogicalTree(newObj)) {
return rebalanceLogicalTree(newObj);
}
// (TypeScript) Ignore `static` in `constructor(static p) {}`
// and `export` in `constructor(export p) {}`
if (
@@ -194,4 +199,32 @@ function clean(ast, newObj, parent) {
}
}
function isUnbalancedLogicalTree(newObj) {
return (
newObj.type === "LogicalExpression" &&
newObj.right.type === "LogicalExpression" &&
newObj.operator === newObj.right.operator
);
}
function rebalanceLogicalTree(newObj) {
if (isUnbalancedLogicalTree(newObj)) {
return rebalanceLogicalTree({
type: "LogicalExpression",
operator: newObj.operator,
left: rebalanceLogicalTree({
type: "LogicalExpression",
operator: newObj.operator,
left: newObj.left,
right: newObj.right.left,
loc: {}
}),
right: newObj.right.right,
loc: {}
});
}
return newObj;
}
module.exports = clean;
+4 -3
View File
@@ -428,7 +428,8 @@ function handleClassComments(
enclosingNode &&
(enclosingNode.type === "ClassDeclaration" ||
enclosingNode.type === "ClassExpression") &&
(enclosingNode.decorators && enclosingNode.decorators.length > 0) &&
enclosingNode.decorators &&
enclosingNode.decorators.length > 0 &&
!(followingNode && followingNode.type === "Decorator")
) {
if (!enclosingNode.decorators || enclosingNode.decorators.length === 0) {
@@ -573,8 +574,8 @@ function handleCommentInEmptyParens(text, enclosingNode, comment, options) {
}
if (
enclosingNode &&
(enclosingNode.type === "MethodDefinition" &&
enclosingNode.value.params.length === 0)
enclosingNode.type === "MethodDefinition" &&
enclosingNode.value.params.length === 0
) {
addDanglingComment(enclosingNode.value, comment);
return true;
+4 -5
View File
@@ -161,11 +161,10 @@ function embed(path, print, textToDoc, options) {
*/
if (
parentParent &&
(parentParent.type === "TaggedTemplateExpression" &&
parent.quasis.length === 1 &&
(parentParent.tag.type === "Identifier" &&
(parentParent.tag.name === "md" ||
parentParent.tag.name === "markdown")))
parentParent.type === "TaggedTemplateExpression" &&
parent.quasis.length === 1 &&
parentParent.tag.type === "Identifier" &&
(parentParent.tag.name === "md" || parentParent.tag.name === "markdown")
) {
const text = parent.quasis[0].value.raw.replace(
/((?:\\\\)*)\\`/g,
+7 -13
View File
@@ -339,8 +339,13 @@ function needsParens(path, options) {
(node.type === "TSTypeAssertion" || node.type === "TSAsExpression")
);
case "BinaryExpression":
case "LogicalExpression": {
case "LogicalExpression":
if (node.type === "LogicalExpression") {
return parent.operator !== node.operator;
}
// else fallthrough
case "BinaryExpression": {
if (!node.operator && node.type !== "TSTypeAssertion") {
return true;
}
@@ -354,17 +359,6 @@ function needsParens(path, options) {
return true;
}
if (
(po === "??" && (no === "||" || no === "&&")) ||
(no === "??" && (po === "||" || po === "&&"))
) {
return true;
}
if (po === "||" && no === "&&") {
return true;
}
if (pp === np && name === "right") {
assert.strictEqual(parent.right, node);
return true;
+19 -16
View File
@@ -597,9 +597,9 @@ function printPathNoParens(path, options, print, args) {
(n === parent.body && parent.type === "ArrowFunctionExpression") ||
(n !== parent.body && parent.type === "ForStatement") ||
(parent.type === "ConditionalExpression" &&
(parentParent.type !== "ReturnStatement" &&
parentParent.type !== "CallExpression" &&
parentParent.type !== "OptionalCallExpression"));
parentParent.type !== "ReturnStatement" &&
parentParent.type !== "CallExpression" &&
parentParent.type !== "OptionalCallExpression");
const shouldIndentIfInlining =
parent.type === "AssignmentExpression" ||
@@ -1625,8 +1625,8 @@ function printPathNoParens(path, options, print, args) {
case "NumericLiteral": // Babel 6 Literal split
return printNumber(n.extra.raw);
case "BigIntLiteral":
// babel: n.extra.raw, typescript: n.raw
return (n.extra ? n.extra.raw : n.raw).toLowerCase();
// babel: n.extra.raw, typescript: n.raw, flow: n.bigint
return (n.bigint || (n.extra ? n.extra.raw : n.raw)).toLowerCase();
case "BooleanLiteral": // Babel 6 Literal split
case "StringLiteral": // Babel 6 Literal split
case "Literal": {
@@ -3601,10 +3601,10 @@ function printPathNoParens(path, options, print, args) {
isNgForOf(n, index, parentNode) ||
(((index === 1 && (n.key.name === "then" || n.key.name === "else")) ||
(index === 2 &&
(n.key.name === "else" &&
parentNode.body[index - 1].type ===
"NGMicrosyntaxKeyedExpression" &&
parentNode.body[index - 1].key.name === "then"))) &&
n.key.name === "else" &&
parentNode.body[index - 1].type ===
"NGMicrosyntaxKeyedExpression" &&
parentNode.body[index - 1].key.name === "then")) &&
parentNode.body[0].type === "NGMicrosyntaxExpression");
return concat([
path.call(print, "key"),
@@ -4450,12 +4450,12 @@ function printExportDeclaration(path, options, print) {
if (
isDefault &&
(decl.declaration.type !== "ClassDeclaration" &&
decl.declaration.type !== "FunctionDeclaration" &&
decl.declaration.type !== "TSInterfaceDeclaration" &&
decl.declaration.type !== "DeclareClass" &&
decl.declaration.type !== "DeclareFunction" &&
decl.declaration.type !== "TSDeclareFunction")
decl.declaration.type !== "ClassDeclaration" &&
decl.declaration.type !== "FunctionDeclaration" &&
decl.declaration.type !== "TSInterfaceDeclaration" &&
decl.declaration.type !== "DeclareClass" &&
decl.declaration.type !== "DeclareFunction" &&
decl.declaration.type !== "TSDeclareFunction"
) {
parts.push(semi);
}
@@ -4587,10 +4587,13 @@ function printTypeParameters(path, options, print, paramsKey) {
(n[paramsKey][0].type === "TSTypeReference" &&
shouldHugType(n[paramsKey][0].typeName)) ||
n[paramsKey][0].type === "NullableTypeAnnotation" ||
// See https://github.com/prettier/prettier/pull/6467 for the context.
(greatGreatGrandParent &&
greatGreatGrandParent.type === "VariableDeclarator" &&
grandparent &&
grandparent.type === "TSTypeAnnotation" &&
n[paramsKey][0].type !== "TSUnionType" &&
n[paramsKey][0].type !== "UnionTypeAnnotation" &&
n[paramsKey][0].type !== "TSConditionalType" &&
n[paramsKey][0].type !== "TSMappedType")));
@@ -5140,7 +5143,7 @@ function separatorNoWhitespace(
if (
(childNode.type === "JSXElement" && !childNode.closingElement) ||
(nextNode && (nextNode.type === "JSXElement" && !nextNode.closingElement))
(nextNode && nextNode.type === "JSXElement" && !nextNode.closingElement)
) {
return child.length === 1 ? softline : hardline;
}
+7 -2
View File
@@ -217,8 +217,13 @@ function getFlowScalarLineContents(nodeType, content, options) {
index !== 0 &&
rawLineContents[index - 1].length !== 0 &&
lineContentWords.length !== 0 &&
!// trailing backslash in quoteDouble should be preserved
(nodeType === "quoteDouble" && getLast(getLast(reduced)).endsWith("\\"))
!(
// trailing backslash in quoteDouble should be preserved
(
nodeType === "quoteDouble" &&
getLast(getLast(reduced)).endsWith("\\")
)
)
? reduced.concat([reduced.pop().concat(lineContentWords)])
: reduced.concat([lineContentWords]),
[]
@@ -2,7 +2,7 @@
exports[`literal.js 1`] = `
====================================options=====================================
parsers: ["babel", "typescript"]
parsers: ["babel", "typescript", "flow"]
printWidth: 80
| printWidth
=====================================input======================================
+1 -1
View File
@@ -1 +1 @@
run_spec(__dirname, ["babel", "typescript"]);
run_spec(__dirname, ["babel", "typescript", "flow"]);
@@ -2102,6 +2102,326 @@ semi: false
================================================================================
`;
exports[`style.vue 1`] = `
====================================options=====================================
parsers: ["vue"]
printWidth: 80
| printWidth
=====================================input======================================
<script>
</script>
<style>
#foo1{ color: #f00;
}
</style>
<style scoped>
#foo2{ color: #f00;
}
</style>
<style lang="css">
#foo3{ color: #f00;
}
</style>
<style lang="css" scoped>
#foo4{ color: #f00;
}
</style>
<style lang="less">
#foo5{ color: #f00;
}
</style>
<style lang="less" scoped>
#foo6{
@color: #f00;
color: @color;
}
</style>
<style lang="scss">
#foo8{
$color: #f00;
color: $color;
}
</style>
<style lang="scss" scoped>
#foo8{
$color: #f00;
color: $color;
}
</style>
=====================================output=====================================
<script></script>
<style>
#foo1 {
color: #f00;
}
</style>
<style scoped>
#foo2 {
color: #f00;
}
</style>
<style lang="css">
#foo3 {
color: #f00;
}
</style>
<style lang="css" scoped>
#foo4 {
color: #f00;
}
</style>
<style lang="less">
#foo5 {
color: #f00;
}
</style>
<style lang="less" scoped>
#foo6 {
@color: #f00;
color: @color;
}
</style>
<style lang="scss">
#foo8 {
$color: #f00;
color: $color;
}
</style>
<style lang="scss" scoped>
#foo8 {
$color: #f00;
color: $color;
}
</style>
================================================================================
`;
exports[`style.vue 2`] = `
====================================options=====================================
parsers: ["vue"]
printWidth: 80
trailingComma: "es5"
| printWidth
=====================================input======================================
<script>
</script>
<style>
#foo1{ color: #f00;
}
</style>
<style scoped>
#foo2{ color: #f00;
}
</style>
<style lang="css">
#foo3{ color: #f00;
}
</style>
<style lang="css" scoped>
#foo4{ color: #f00;
}
</style>
<style lang="less">
#foo5{ color: #f00;
}
</style>
<style lang="less" scoped>
#foo6{
@color: #f00;
color: @color;
}
</style>
<style lang="scss">
#foo8{
$color: #f00;
color: $color;
}
</style>
<style lang="scss" scoped>
#foo8{
$color: #f00;
color: $color;
}
</style>
=====================================output=====================================
<script></script>
<style>
#foo1 {
color: #f00;
}
</style>
<style scoped>
#foo2 {
color: #f00;
}
</style>
<style lang="css">
#foo3 {
color: #f00;
}
</style>
<style lang="css" scoped>
#foo4 {
color: #f00;
}
</style>
<style lang="less">
#foo5 {
color: #f00;
}
</style>
<style lang="less" scoped>
#foo6 {
@color: #f00;
color: @color;
}
</style>
<style lang="scss">
#foo8 {
$color: #f00;
color: $color;
}
</style>
<style lang="scss" scoped>
#foo8 {
$color: #f00;
color: $color;
}
</style>
================================================================================
`;
exports[`style.vue 3`] = `
====================================options=====================================
parsers: ["vue"]
printWidth: 80
semi: false
| printWidth
=====================================input======================================
<script>
</script>
<style>
#foo1{ color: #f00;
}
</style>
<style scoped>
#foo2{ color: #f00;
}
</style>
<style lang="css">
#foo3{ color: #f00;
}
</style>
<style lang="css" scoped>
#foo4{ color: #f00;
}
</style>
<style lang="less">
#foo5{ color: #f00;
}
</style>
<style lang="less" scoped>
#foo6{
@color: #f00;
color: @color;
}
</style>
<style lang="scss">
#foo8{
$color: #f00;
color: $color;
}
</style>
<style lang="scss" scoped>
#foo8{
$color: #f00;
color: $color;
}
</style>
=====================================output=====================================
<script></script>
<style>
#foo1 {
color: #f00;
}
</style>
<style scoped>
#foo2 {
color: #f00;
}
</style>
<style lang="css">
#foo3 {
color: #f00;
}
</style>
<style lang="css" scoped>
#foo4 {
color: #f00;
}
</style>
<style lang="less">
#foo5 {
color: #f00;
}
</style>
<style lang="less" scoped>
#foo6 {
@color: #f00;
color: @color;
}
</style>
<style lang="scss">
#foo8 {
$color: #f00;
color: $color;
}
</style>
<style lang="scss" scoped>
#foo8 {
$color: #f00;
color: $color;
}
</style>
================================================================================
`;
exports[`tag-name.vue 1`] = `
====================================options=====================================
parsers: ["vue"]
+46
View File
@@ -0,0 +1,46 @@
<script>
</script>
<style>
#foo1{ color: #f00;
}
</style>
<style scoped>
#foo2{ color: #f00;
}
</style>
<style lang="css">
#foo3{ color: #f00;
}
</style>
<style lang="css" scoped>
#foo4{ color: #f00;
}
</style>
<style lang="less">
#foo5{ color: #f00;
}
</style>
<style lang="less" scoped>
#foo6{
@color: #f00;
color: @color;
}
</style>
<style lang="scss">
#foo8{
$color: #f00;
color: $color;
}
</style>
<style lang="scss" scoped>
#foo8{
$color: #f00;
color: $color;
}
</style>
@@ -0,0 +1,77 @@
// Jest Snapshot v1, https://goo.gl/fbAQLP
exports[`logical_expression_operators.js 1`] = `
====================================options=====================================
parsers: ["babel", "flow", "typescript"]
printWidth: 80
| printWidth
=====================================input======================================
// Same operators do not require parens
(foo && bar) && baz;
foo && (bar && baz);
foo && ((bar && baz) && qux);
foo && (bar && (baz && qux));
foo && (bar && ((baz && qux) && xyz));
foo && (bar && (baz && (qux && xyz)));
(foo || bar) || baz;
foo || (bar || baz);
foo || ((bar || baz) || qux);
foo || (bar || (baz || qux));
foo || (bar || ((baz || qux) || xyz));
foo || (bar || (baz || (qux || xyz)));
(foo ?? bar) ?? baz;
foo ?? (bar ?? baz);
foo ?? ((bar ?? baz) ?? qux);
foo ?? (bar ?? (baz ?? qux));
foo ?? (bar ?? ((baz ?? qux) ?? xyz));
foo ?? (bar ?? (baz ?? (qux ?? xyz)));
// Explicitly parenthesized && and || requires parens
(foo && bar) || baz;
(foo || bar) && baz;
foo && (bar || baz);
foo || (bar && baz);
// Implicitly parenthesized && and || requires parens
foo && bar || baz;
foo || bar && baz;
=====================================output=====================================
// Same operators do not require parens
foo && bar && baz;
foo && bar && baz;
foo && bar && baz && qux;
foo && bar && baz && qux;
foo && bar && baz && qux && xyz;
foo && bar && baz && qux && xyz;
foo || bar || baz;
foo || bar || baz;
foo || bar || baz || qux;
foo || bar || baz || qux;
foo || bar || baz || qux || xyz;
foo || bar || baz || qux || xyz;
foo ?? bar ?? baz;
foo ?? bar ?? baz;
foo ?? bar ?? baz ?? qux;
foo ?? bar ?? baz ?? qux;
foo ?? bar ?? baz ?? qux ?? xyz;
foo ?? bar ?? baz ?? qux ?? xyz;
// Explicitly parenthesized && and || requires parens
(foo && bar) || baz;
(foo || bar) && baz;
foo && (bar || baz);
foo || (bar && baz);
// Implicitly parenthesized && and || requires parens
(foo && bar) || baz;
foo || (bar && baz);
================================================================================
`;
+1
View File
@@ -0,0 +1 @@
run_spec(__dirname, ["babel", "flow", "typescript"]);
@@ -0,0 +1,32 @@
// Same operators do not require parens
(foo && bar) && baz;
foo && (bar && baz);
foo && ((bar && baz) && qux);
foo && (bar && (baz && qux));
foo && (bar && ((baz && qux) && xyz));
foo && (bar && (baz && (qux && xyz)));
(foo || bar) || baz;
foo || (bar || baz);
foo || ((bar || baz) || qux);
foo || (bar || (baz || qux));
foo || (bar || ((baz || qux) || xyz));
foo || (bar || (baz || (qux || xyz)));
(foo ?? bar) ?? baz;
foo ?? (bar ?? baz);
foo ?? ((bar ?? baz) ?? qux);
foo ?? (bar ?? (baz ?? qux));
foo ?? (bar ?? ((baz ?? qux) ?? xyz));
foo ?? (bar ?? (baz ?? (qux ?? xyz)));
// Explicitly parenthesized && and || requires parens
(foo && bar) || baz;
(foo || bar) && baz;
foo && (bar || baz);
foo || (bar && baz);
// Implicitly parenthesized && and || requires parens
foo && bar || baz;
foo || bar && baz;
@@ -36,7 +36,7 @@ const x = (foo, bar = foo ?? bar) => {};
foo ? bar ?? foo : baz;
foo ?? (bar ?? baz);
foo ?? bar ?? baz;
foo ?? bar ?? baz;
// Mixing ?? and (&& or ||) requires parens
@@ -1,5 +1,38 @@
// Jest Snapshot v1, https://goo.gl/fbAQLP
exports[`arrow-return-type.ts 1`] = `
====================================options=====================================
parsers: ["typescript"]
printWidth: 80
| printWidth
=====================================input======================================
export const getVehicleDescriptor = async (
vehicleId: string,
): Promise<
Descriptor | undefined
> => {}
export const getVehicleDescriptor = async (
vehicleId: string,
): Promise<
Collections.Parts.PrintedCircuitBoardAssembly['attributes'] | undefined
> => {}
=====================================output=====================================
export const getVehicleDescriptor = async (
vehicleId: string
): Promise<Descriptor | undefined> => {};
export const getVehicleDescriptor = async (
vehicleId: string
): Promise<
Collections.Parts.PrintedCircuitBoardAssembly["attributes"] | undefined
> => {};
================================================================================
`;
exports[`object-method.ts 1`] = `
====================================options=====================================
parsers: ["typescript"]
@@ -0,0 +1,12 @@
export const getVehicleDescriptor = async (
vehicleId: string,
): Promise<
Descriptor | undefined
> => {}
export const getVehicleDescriptor = async (
vehicleId: string,
): Promise<
Collections.Parts.PrintedCircuitBoardAssembly['attributes'] | undefined
> => {}
@@ -1,5 +1,12 @@
// Jest Snapshot v1, https://goo.gl/fbAQLP
exports[`'Adjacent JSX' error should not be swallowed by Babel's error recovery 1`] = `
"Adjacent JSX elements must be wrapped in an enclosing tag. Did you want a JSX fragment <>...</>? (2:1)
1 | <a></a>
> 2 | <b></b>
| ^"
`;
exports[`html parser should handle CRLF correctly 1`] = `"\\"<!--\\\\r\\\\n test\\\\r\\\\n test\\\\r\\\\n-->\\\\r\\\\n\\""`;
exports[`markdown parser should handle CRLF correctly 1`] = `"\\"\`\`\`\\\\r\\\\n\\\\r\\\\n\\\\r\\\\n\`\`\`\\\\r\\\\n\\""`;
@@ -367,6 +367,11 @@ in order for it to be formatted.",
"description": "Indent with tabs instead of spaces.",
"type": "boolean",
},
"vueIndentScriptAndStyle": Object {
"default": false,
"description": "Indent script and style tags in Vue files.",
"type": "boolean",
},
},
"type": "object",
},
@@ -645,7 +645,19 @@ exports[`API getSupportInfo() with version 1.16.0 -> undefined 1`] = `
\\"default\\": Infinity,
\\"range\\": Object {
\\"end\\": Infinity,
\\"start\\": 0,"
\\"start\\": 0,
@@ -220,7 +233,11 @@
},
\\"useTabs\\": Object {
\\"default\\": false,
\\"type\\": \\"boolean\\",
},
+ \\"vueIndentScriptAndStyle\\": Object {
+ \\"default\\": false,
+ \\"type\\": \\"boolean\\",
},
+ },
}"
`;
exports[`CLI --support-info (stderr) 1`] = `""`;
@@ -1400,6 +1412,15 @@ exports[`CLI --support-info (stdout) 1`] = `
\\"pluginDefaults\\": {},
\\"since\\": \\"1.0.0\\",
\\"type\\": \\"boolean\\"
},
{
\\"category\\": \\"HTML\\",
\\"default\\": false,
\\"description\\": \\"Indent script and style tags in Vue files.\\",
\\"name\\": \\"vueIndentScriptAndStyle\\",
\\"pluginDefaults\\": {},
\\"since\\": \\"1.19.0\\",
\\"type\\": \\"boolean\\"
}
]
}
+5
View File
@@ -53,3 +53,8 @@ test("should work with foo plugin instance", () => {
`"\\"{\\\\\\"tabWidth\\\\\\":8,\\\\\\"bracketSpacing\\\\\\":false}\\""`
);
});
test("'Adjacent JSX' error should not be swallowed by Babel's error recovery", () => {
const input = "<a></a>\n<b></b>";
expect(() => prettier.format(input)).toThrowErrorMatchingSnapshot();
});
+5 -3
View File
@@ -165,9 +165,11 @@ describe("--write and --list-different with unknown path and no parser", () => {
});
describe("multiple files", () => {
runPrettier("cli/infer-parser/", ["--list-different", "--write", "*"]).test(
{ status: 0 }
);
runPrettier("cli/infer-parser/", [
"--list-different",
"--write",
"*"
]).test({ status: 0 });
});
});
+4 -4
View File
@@ -468,10 +468,10 @@ In 1.0, we made class be inline inside of arrow functions. It turns out that it
```js
// Before
export default (ViewComponent: Function, ContainerComponent: Function) => class
extends React.Component {
static propTypes = {};
};
export default (ViewComponent: Function, ContainerComponent: Function) =>
class extends React.Component {
static propTypes = {};
};
// After
export default (ViewComponent: Function, ContainerComponent: Function) =>
File diff suppressed because it is too large. Load diff
+1 -1
View File
@@ -19,7 +19,7 @@
"react-dom": "16.11.0"
},
"devDependencies": {
"@babel/preset-env": "7.6.3",
"@babel/preset-env": "7.7.1",
"@babel/preset-react": "7.7.0",
"@sandhose/prettier-animated-logo": "1.0.3",
"babel-loader": "8.0.6",
+3 -1
View File
@@ -50,7 +50,7 @@ prettier.resolveConfig(filePath).then(options => {
});
```
If `options.editorconfig` is `true` and an [`.editorconfig` file](http://editorconfig.org/) is in your project, Prettier will parse it and convert its properties to the corresponding prettier configuration. This configuration will be overridden by `.prettierrc`, etc. Currently, the following EditorConfig properties are supported:
If `options.editorconfig` is `true` and an [`.editorconfig` file](https://editorconfig.org/) is in your project, Prettier will parse it and convert its properties to the corresponding prettier configuration. This configuration will be overridden by `.prettierrc`, etc. Currently, the following EditorConfig properties are supported:
- `end_of_line`
- `indent_style`
@@ -101,6 +101,8 @@ Setting `options.ignorePath` (`string`) and `options.withNodeModules` (`boolean`
Providing [plugin](plugins.md) paths in `options.plugins` (`string[]`) helps extract `inferredParser` for files that are not supported by Prettier core.
When setting `options.resolveConfig` (`boolean`, default `false`), Prettier will resolve the configuration for the given `filePath`. This is useful, for example, when the `inferredParser` might be overridden for a subset of files.
Use `prettier.getFileInfo.sync(filePath [, options])` if you'd like to use sync version.
## `prettier.getSupportInfo([version])`
@@ -4,7 +4,7 @@ title: Browser
original_id: browser
---
Run Prettier in the browser with the `standalone.js` UMD bundle shipped in the NPM package (starting in version 1.13). The new UMD bundle only formats the code and has no support for config files, ignore files, CLI usage, or automatic loading of plugins.
Run Prettier in the browser with the `standalone.js` UMD bundle shipped in the NPM package (starting in version 1.13). The UMD bundle only formats the code and has no support for config files, ignore files, CLI usage, or automatic loading of plugins.
### `prettier.format(code, options)`
@@ -16,12 +16,14 @@ See [Usage](#usage) below for examples.
### Global
<!-- prettier-ignore -->
```html
<script src="https://unpkg.com/prettier@1.13.0/standalone.js"></script>
<script src="https://unpkg.com/prettier@1.13.0/parser-graphql.js"></script>
<script type="text/javascript">
prettier.format("query { }", { parser: "graphql", plugins: prettierPlugins });
<script src="https://unpkg.com/prettier@1.19.1/standalone.js"></script>
<script src="https://unpkg.com/prettier@1.19.1/parser-graphql.js"></script>
<script>
prettier.format("query { }", {
parser: "graphql",
plugins: prettierPlugins
});
</script>
```
@@ -41,8 +43,8 @@ prettier.format("query { }", {
```js
define([
"https://unpkg.com/prettier@1.13.0/standalone.js",
"https://unpkg.com/prettier@1.13.0/parser-graphql.js"
"https://unpkg.com/prettier@1.19.1/standalone.js",
"https://unpkg.com/prettier@1.19.1/parser-graphql.js"
], (prettier, ...plugins) => {
prettier.format("query { }", { parser: "graphql", plugins });
});
@@ -61,7 +63,7 @@ This syntax doesn't necessarily work in the browser, but it can be used when bun
### Worker
```js
importScripts("https://unpkg.com/prettier@1.13.0/standalone.js");
importScripts("https://unpkg.com/prettier@1.13.0/parser-graphql.js");
importScripts("https://unpkg.com/prettier@1.19.1/standalone.js");
importScripts("https://unpkg.com/prettier@1.19.1/parser-graphql.js");
prettier.format("query { }", { parser: "graphql", plugins: prettierPlugins });
```
+1 -3
View File
@@ -18,7 +18,7 @@ In practice, this may look something like:
prettier --single-quote --trailing-comma es5 --write "{app,__{tests,mocks}__}/**/*.js"
```
Don't forget the quotes around the globs! The quotes make sure that Prettier expands the globs rather than your shell, for cross-platform usage. The [glob syntax from the `fast-glob` module](https://github.com/mrmlnc/fast-glob/blob/master/README.md#pattern-syntax) is used.
Don't forget the quotes around the globs! The quotes make sure that Prettier expands the globs rather than your shell, for cross-platform usage. The [glob syntax from the glob module](https://github.com/isaacs/node-glob/blob/master/README.md#glob-primer) is used.
Prettier CLI will ignore files located in `node_modules` directory. To opt-out from this behavior use `--with-node-modules` flag.
@@ -149,8 +149,6 @@ Prettier CLI will ignore files located in `node_modules` directory. To opt-out f
This rewrites all processed files in place. This is comparable to the `eslint --fix` workflow.
To avoid re-checking unchanged files, use the `--only-changed` flag.
## `--loglevel`
Change the level of logging for the CLI. Valid options are:
@@ -8,10 +8,10 @@ original_id: comparison
Linters have two categories of rules:
**Formatting rules**: eg: [max-len](http://eslint.org/docs/rules/max-len), [no-mixed-spaces-and-tabs](http://eslint.org/docs/rules/no-mixed-spaces-and-tabs), [keyword-spacing](http://eslint.org/docs/rules/keyword-spacing), [comma-style](http://eslint.org/docs/rules/comma-style)...
**Formatting rules**: eg: [max-len](https://eslint.org/docs/rules/max-len), [no-mixed-spaces-and-tabs](https://eslint.org/docs/rules/no-mixed-spaces-and-tabs), [keyword-spacing](https://eslint.org/docs/rules/keyword-spacing), [comma-style](https://eslint.org/docs/rules/comma-style)...
Prettier alleviates the need for this whole category of rules! Prettier is going to reprint the entire program from scratch in a consistent way, so it's not possible for the programmer to make a mistake there anymore :)
**Code-quality rules**: eg [no-unused-vars](http://eslint.org/docs/rules/no-unused-vars), [no-extra-bind](http://eslint.org/docs/rules/no-extra-bind), [no-implicit-globals](http://eslint.org/docs/rules/no-implicit-globals), [prefer-promise-reject-errors](http://eslint.org/docs/rules/prefer-promise-reject-errors)...
**Code-quality rules**: eg [no-unused-vars](https://eslint.org/docs/rules/no-unused-vars), [no-extra-bind](https://eslint.org/docs/rules/no-extra-bind), [no-implicit-globals](https://eslint.org/docs/rules/no-implicit-globals), [prefer-promise-reject-errors](https://eslint.org/docs/rules/prefer-promise-reject-errors)...
Prettier does nothing to help with those kind of rules. They are also the most important ones provided by linters as they are likely to catch real bugs with your code!
@@ -64,7 +64,7 @@ singleQuote = true
Overrides let you have different configuration for certain file extensions, folders and specific files.
Prettier borrows ESLint’s [override format](http://eslint.org/docs/user-guide/configuring#example-configuration).
Prettier borrows ESLint’s [override format](https://eslint.org/docs/user-guide/configuring#example-configuration).
JSON:
@@ -19,7 +19,7 @@ Prettier is an opinionated code formatter with support for:
- [Markdown](https://commonmark.org/), including [GFM](https://github.github.com/gfm/) and [MDX](https://mdxjs.com/)
- [YAML](https://yaml.org/)
It removes all original styling[\*](#footnotes) and ensures that all outputted code conforms to a consistent style. (See this [blog post](http://jlongster.com/A-Prettier-Formatter))
It removes all original styling[\*](#footnotes) and ensures that all outputted code conforms to a consistent style. (See this [blog post](https://jlongster.com/A-Prettier-Formatter))
Prettier takes your code and reprints it from scratch by taking the line length into account.
@@ -308,6 +308,21 @@ Valid options:
| ------- | ------------------------------------------------------------------------ | ----------------------------------------------------------------------- |
| `"css"` | <code>--html-whitespace-sensitivity <css&#124;strict&#124;ignore></code> | <code>htmlWhitespaceSensitivity: "<css&#124;strict&#124;ignore>"</code> |
## Vue files script and style tags indentation
_First available in v1.19.0_
Whether or not to indent the code inside `<script>` and `<style>` tags in Vue files. Some people (like [the creator of Vue](https://github.com/prettier/prettier/issues/3888#issuecomment-459521863)) don’t indent to save an indentation level, but this might break code folding in your editor.
Valid options:
- `"false"` - Do not indent script and style tags in Vue files.
- `"true"` - Indent script and style tags in Vue files.
| Default | CLI Override | API Override |
| ------- | ------------------------------- | --------------------------------- |
| `false` | `--vue-indent-script-and-style` | `vueIndentScriptAndStyle: <bool>` |
## End of Line
_First available in 1.15.0_
@@ -53,6 +53,7 @@ Providing at least one path to `--plugin-search-dir`/`pluginSearchDirs` turns of
- [`prettier-plugin-elm`](https://github.com/gicentre/prettier-plugin-elm) by [**@giCentre**](https://github.com/gicentre)
- [`prettier-plugin-java`](https://github.com/jhipster/prettier-java) by [**@JHipster**](https://github.com/jhipster)
- [`prettier-plugin-kotlin`](https://github.com/Angry-Potato/prettier-plugin-kotlin) by [**@Angry-Potato**](https://github.com/Angry-Potato)
- [`prettier-plugin-package`](https://github.com/shellscape/prettier-plugin-package) by [**@shellscape**](https://github.com/shellscape)
- [`prettier-plugin-packagejson`](https://github.com/matzkoh/prettier-plugin-packagejson) by [**@matzkoh**](https://github.com/matzkoh)
- [`prettier-plugin-pg`](https://github.com/benjie/prettier-plugin-pg) by [**@benjie**](https://github.com/benjie)
- [`prettier-plugin-solidity`](https://github.com/prettier-solidity/prettier-plugin-solidity) by [**@mattiaerre**](https://github.com/mattiaerre)
@@ -133,9 +133,11 @@ One final thing: TC39 has [not yet decided if decorators come before or after `e
```js
@decorator
export class Foo { }
export class Foo {}
export @decorator class Foo { }
export
@decorator
class Foo {}
```
### Semicolons
@@ -4,7 +4,7 @@ title: Technical Details
original_id: technical-details
---
This printer is a fork of [recast](https://github.com/benjamn/recast)'s printer with its algorithm replaced by the one described by Wadler in "[A prettier printer](http://homepages.inf.ed.ac.uk/wadler/papers/prettier/prettier.pdf)". There still may be leftover code from recast that needs to be cleaned up.
This printer is a fork of [recast](https://github.com/benjamn/recast)'s printer with its algorithm replaced by the one described by Wadler in "[A prettier printer](https://homepages.inf.ed.ac.uk/wadler/papers/prettier/prettier.pdf)". There still may be leftover code from recast that needs to be cleaned up.
The basic idea is that the printer takes an AST and returns an intermediate representation of the output, and the printer uses that to generate a string. The advantage is that the printer can "measure" the IR and see if the output is going to fit on a line, and break if not.
@@ -40,7 +40,7 @@ In older IDE versions, select Custom and do the following configuration:
### Using Prettier with ESLint
If you are using ESLint with [eslint-plugin-prettier](https://github.com/prettier/eslint-plugin-prettier), use the `Fix ESLint Problems` action to reformat the currect file – find it using _Find Action_ (`Cmd/Ctrl-Shift-A`) or [add a keyboard shortcut](https://www.jetbrains.com/help/webstorm/configuring-keyboard-shortcuts.html) to it in _Preferences | Keymap_ and then use it.
If you are using ESLint with [eslint-plugin-prettier](https://github.com/prettier/eslint-plugin-prettier), use the `Fix ESLint Problems` action to reformat the current file – find it using _Find Action_ (`Cmd/Ctrl-Shift-A`) or [add a keyboard shortcut](https://www.jetbrains.com/help/webstorm/configuring-keyboard-shortcuts.html) to it in _Preferences | Keymap_ and then use it.
Make sure that the ESLint integration is enabled in _Preferences | Languages & Frameworks | JavaScript | Code Quality Tools | ESLint_.
+252 -140
View File
@@ -46,6 +46,16 @@
lodash "^4.17.13"
source-map "^0.5.0"
"@babel/generator@^7.7.2":
version "7.7.2"
resolved "https://registry.yarnpkg.com/@babel/generator/-/generator-7.7.2.tgz#2f4852d04131a5e17ea4f6645488b5da66ebf3af"
integrity sha512-WthSArvAjYLz4TcbKOi88me+KmDJdKSlfwwN8CnUYn9jBkzhq0ZEPuBfkAWIvjJ3AdEV1Cf/+eSQTnp3IDJKlQ==
dependencies:
"@babel/types" "^7.7.2"
jsesc "^2.5.1"
lodash "^4.17.13"
source-map "^0.5.0"
"@babel/helper-annotate-as-pure@^7.0.0":
version "7.0.0"
resolved "https://registry.yarnpkg.com/@babel/helper-annotate-as-pure/-/helper-annotate-as-pure-7.0.0.tgz#323d39dd0b50e10c7c06ca7d7638e6864d8c5c32"
@@ -53,6 +63,13 @@
dependencies:
"@babel/types" "^7.0.0"
"@babel/helper-annotate-as-pure@^7.7.0":
version "7.7.0"
resolved "https://registry.yarnpkg.com/@babel/helper-annotate-as-pure/-/helper-annotate-as-pure-7.7.0.tgz#efc54032d43891fe267679e63f6860aa7dbf4a5e"
integrity sha512-k50CQxMlYTYo+GGyUGFwpxKVtxVJi9yh61sXZji3zYHccK9RYliZGSTOgci85T+r+0VFN2nWbGM04PIqwfrpMg==
dependencies:
"@babel/types" "^7.7.0"
"@babel/helper-builder-binary-assignment-operator-visitor@^7.1.0":
version "7.1.0"
resolved "https://registry.yarnpkg.com/@babel/helper-builder-binary-assignment-operator-visitor/-/helper-builder-binary-assignment-operator-visitor-7.1.0.tgz#6b69628dfe4087798e0c4ed98e3d4a6b2fbd2f5f"
@@ -90,13 +107,21 @@
"@babel/helper-replace-supers" "^7.5.5"
"@babel/helper-split-export-declaration" "^7.4.4"
"@babel/helper-define-map@^7.5.5":
version "7.5.5"
resolved "https://registry.yarnpkg.com/@babel/helper-define-map/-/helper-define-map-7.5.5.tgz#3dec32c2046f37e09b28c93eb0b103fd2a25d369"
integrity sha512-fTfxx7i0B5NJqvUOBBGREnrqbTxRh7zinBANpZXAVDlsZxYdclDp467G1sQ8VZYMnAURY3RpBUAgOYT9GfzHBg==
"@babel/helper-create-regexp-features-plugin@^7.7.0":
version "7.7.2"
resolved "https://registry.yarnpkg.com/@babel/helper-create-regexp-features-plugin/-/helper-create-regexp-features-plugin-7.7.2.tgz#6f20443778c8fce2af2ff4206284afc0ced65db6"
integrity sha512-pAil/ZixjTlrzNpjx+l/C/wJk002Wo7XbbZ8oujH/AoJ3Juv0iN/UTcPUHXKMFLqsfS0Hy6Aow8M31brUYBlQQ==
dependencies:
"@babel/helper-function-name" "^7.1.0"
"@babel/types" "^7.5.5"
"@babel/helper-regex" "^7.4.4"
regexpu-core "^4.6.0"
"@babel/helper-define-map@^7.7.0":
version "7.7.0"
resolved "https://registry.yarnpkg.com/@babel/helper-define-map/-/helper-define-map-7.7.0.tgz#60b0e9fd60def9de5054c38afde8c8ee409c7529"
integrity sha512-kPKWPb0dMpZi+ov1hJiwse9dWweZsz3V9rP4KdytnX1E7z3cTNmFGglwklzFPuqIcHLIY3bgKSs4vkwXXdflQA==
dependencies:
"@babel/helper-function-name" "^7.7.0"
"@babel/types" "^7.7.0"
lodash "^4.17.13"
"@babel/helper-explode-assignable-expression@^7.1.0":
@@ -116,6 +141,15 @@
"@babel/template" "^7.1.0"
"@babel/types" "^7.0.0"
"@babel/helper-function-name@^7.7.0":
version "7.7.0"
resolved "https://registry.yarnpkg.com/@babel/helper-function-name/-/helper-function-name-7.7.0.tgz#44a5ad151cfff8ed2599c91682dda2ec2c8430a3"
integrity sha512-tDsJgMUAP00Ugv8O2aGEua5I2apkaQO7lBGUq1ocwN3G23JE5Dcq0uh3GvFTChPa4b40AWiAsLvCZOA2rdnQ7Q==
dependencies:
"@babel/helper-get-function-arity" "^7.7.0"
"@babel/template" "^7.7.0"
"@babel/types" "^7.7.0"
"@babel/helper-get-function-arity@^7.0.0":
version "7.0.0"
resolved "https://registry.yarnpkg.com/@babel/helper-get-function-arity/-/helper-get-function-arity-7.0.0.tgz#83572d4320e2a4657263734113c42868b64e49c3"
@@ -123,6 +157,13 @@
dependencies:
"@babel/types" "^7.0.0"
"@babel/helper-get-function-arity@^7.7.0":
version "7.7.0"
resolved "https://registry.yarnpkg.com/@babel/helper-get-function-arity/-/helper-get-function-arity-7.7.0.tgz#c604886bc97287a1d1398092bc666bc3d7d7aa2d"
integrity sha512-tLdojOTz4vWcEnHWHCuPN5P85JLZWbm5Fx5ZsMEMPhF3Uoe3O7awrbM2nQ04bDOUToH/2tH/ezKEOR8zEYzqyw==
dependencies:
"@babel/types" "^7.7.0"
"@babel/helper-hoist-variables@^7.4.4":
version "7.4.4"
resolved "https://registry.yarnpkg.com/@babel/helper-hoist-variables/-/helper-hoist-variables-7.4.4.tgz#0298b5f25c8c09c53102d52ac4a98f773eb2850a"
@@ -130,6 +171,13 @@
dependencies:
"@babel/types" "^7.4.4"
"@babel/helper-hoist-variables@^7.7.0":
version "7.7.0"
resolved "https://registry.yarnpkg.com/@babel/helper-hoist-variables/-/helper-hoist-variables-7.7.0.tgz#b4552e4cfe5577d7de7b183e193e84e4ec538c81"
integrity sha512-LUe/92NqsDAkJjjCEWkNe+/PcpnisvnqdlRe19FahVapa4jndeuJ+FBiTX1rcAKWKcJGE+C3Q3tuEuxkSmCEiQ==
dependencies:
"@babel/types" "^7.7.0"
"@babel/helper-member-expression-to-functions@^7.5.5":
version "7.5.5"
resolved "https://registry.yarnpkg.com/@babel/helper-member-expression-to-functions/-/helper-member-expression-to-functions-7.5.5.tgz#1fb5b8ec4453a93c439ee9fe3aeea4a84b76b590"
@@ -137,12 +185,19 @@
dependencies:
"@babel/types" "^7.5.5"
"@babel/helper-module-imports@^7.0.0":
version "7.0.0"
resolved "https://registry.yarnpkg.com/@babel/helper-module-imports/-/helper-module-imports-7.0.0.tgz#96081b7111e486da4d2cd971ad1a4fe216cc2e3d"
integrity sha512-aP/hlLq01DWNEiDg4Jn23i+CXxW/owM4WpDLFUbpjxe4NS3BhLVZQ5i7E0ZrxuQ/vwekIeciyamgB1UIYxxM6A==
"@babel/helper-member-expression-to-functions@^7.7.0":
version "7.7.0"
resolved "https://registry.yarnpkg.com/@babel/helper-member-expression-to-functions/-/helper-member-expression-to-functions-7.7.0.tgz#472b93003a57071f95a541ea6c2b098398bcad8a"
integrity sha512-QaCZLO2RtBcmvO/ekOLp8p7R5X2JriKRizeDpm5ChATAFWrrYDcDxPuCIBXKyBjY+i1vYSdcUTMIb8psfxHDPA==
dependencies:
"@babel/types" "^7.0.0"
"@babel/types" "^7.7.0"
"@babel/helper-module-imports@^7.0.0", "@babel/helper-module-imports@^7.7.0":
version "7.7.0"
resolved "https://registry.yarnpkg.com/@babel/helper-module-imports/-/helper-module-imports-7.7.0.tgz#99c095889466e5f7b6d66d98dffc58baaf42654d"
integrity sha512-Dv3hLKIC1jyfTkClvyEkYP2OlkzNvWs5+Q8WgPbxM5LMeorons7iPP91JM+DU7tRbhqA1ZeooPaMFvQrn23RHw==
dependencies:
"@babel/types" "^7.7.0"
"@babel/helper-module-transforms@^7.1.0":
version "7.2.2"
@@ -156,16 +211,16 @@
"@babel/types" "^7.2.2"
lodash "^4.17.10"
"@babel/helper-module-transforms@^7.4.4":
version "7.5.5"
resolved "https://registry.yarnpkg.com/@babel/helper-module-transforms/-/helper-module-transforms-7.5.5.tgz#f84ff8a09038dcbca1fd4355661a500937165b4a"
integrity sha512-jBeCvETKuJqeiaCdyaheF40aXnnU1+wkSiUs/IQg3tB85up1LyL8x77ClY8qJpuRJUcXQo+ZtdNESmZl4j56Pw==
"@babel/helper-module-transforms@^7.7.0":
version "7.7.0"
resolved "https://registry.yarnpkg.com/@babel/helper-module-transforms/-/helper-module-transforms-7.7.0.tgz#154a69f0c5b8fd4d39e49750ff7ac4faa3f36786"
integrity sha512-rXEefBuheUYQyX4WjV19tuknrJFwyKw0HgzRwbkyTbB+Dshlq7eqkWbyjzToLrMZk/5wKVKdWFluiAsVkHXvuQ==
dependencies:
"@babel/helper-module-imports" "^7.0.0"
"@babel/helper-simple-access" "^7.1.0"
"@babel/helper-split-export-declaration" "^7.4.4"
"@babel/template" "^7.4.4"
"@babel/types" "^7.5.5"
"@babel/helper-module-imports" "^7.7.0"
"@babel/helper-simple-access" "^7.7.0"
"@babel/helper-split-export-declaration" "^7.7.0"
"@babel/template" "^7.7.0"
"@babel/types" "^7.7.0"
lodash "^4.17.13"
"@babel/helper-optimise-call-expression@^7.0.0":
@@ -175,6 +230,13 @@
dependencies:
"@babel/types" "^7.0.0"
"@babel/helper-optimise-call-expression@^7.7.0":
version "7.7.0"
resolved "https://registry.yarnpkg.com/@babel/helper-optimise-call-expression/-/helper-optimise-call-expression-7.7.0.tgz#4f66a216116a66164135dc618c5d8b7a959f9365"
integrity sha512-48TeqmbazjNU/65niiiJIJRc5JozB8acui1OS7bSd6PgxfuovWsvjfWSzlgx+gPFdVveNzUdpdIg5l56Pl5jqg==
dependencies:
"@babel/types" "^7.7.0"
"@babel/helper-plugin-utils@^7.0.0":
version "7.0.0"
resolved "https://registry.yarnpkg.com/@babel/helper-plugin-utils/-/helper-plugin-utils-7.0.0.tgz#bbb3fbee98661c569034237cc03967ba99b4f250"
@@ -194,16 +256,16 @@
dependencies:
lodash "^4.17.13"
"@babel/helper-remap-async-to-generator@^7.1.0":
version "7.1.0"
resolved "https://registry.yarnpkg.com/@babel/helper-remap-async-to-generator/-/helper-remap-async-to-generator-7.1.0.tgz#361d80821b6f38da75bd3f0785ece20a88c5fe7f"
integrity sha512-3fOK0L+Fdlg8S5al8u/hWE6vhufGSn0bN09xm2LXMy//REAF8kDCrYoOBKYmA8m5Nom+sV9LyLCwrFynA8/slg==
"@babel/helper-remap-async-to-generator@^7.7.0":
version "7.7.0"
resolved "https://registry.yarnpkg.com/@babel/helper-remap-async-to-generator/-/helper-remap-async-to-generator-7.7.0.tgz#4d69ec653e8bff5bce62f5d33fc1508f223c75a7"
integrity sha512-pHx7RN8X0UNHPB/fnuDnRXVZ316ZigkO8y8D835JlZ2SSdFKb6yH9MIYRU4fy/KPe5sPHDFOPvf8QLdbAGGiyw==
dependencies:
"@babel/helper-annotate-as-pure" "^7.0.0"
"@babel/helper-wrap-function" "^7.1.0"
"@babel/template" "^7.1.0"
"@babel/traverse" "^7.1.0"
"@babel/types" "^7.0.0"
"@babel/helper-annotate-as-pure" "^7.7.0"
"@babel/helper-wrap-function" "^7.7.0"
"@babel/template" "^7.7.0"
"@babel/traverse" "^7.7.0"
"@babel/types" "^7.7.0"
"@babel/helper-replace-supers@^7.5.5":
version "7.5.5"
@@ -215,6 +277,16 @@
"@babel/traverse" "^7.5.5"
"@babel/types" "^7.5.5"
"@babel/helper-replace-supers@^7.7.0":
version "7.7.0"
resolved "https://registry.yarnpkg.com/@babel/helper-replace-supers/-/helper-replace-supers-7.7.0.tgz#d5365c8667fe7cbd13b8ddddceb9bd7f2b387512"
integrity sha512-5ALYEul5V8xNdxEeWvRsBzLMxQksT7MaStpxjJf9KsnLxpAKBtfw5NeMKZJSYDa0lKdOcy0g+JT/f5mPSulUgg==
dependencies:
"@babel/helper-member-expression-to-functions" "^7.7.0"
"@babel/helper-optimise-call-expression" "^7.7.0"
"@babel/traverse" "^7.7.0"
"@babel/types" "^7.7.0"
"@babel/helper-simple-access@^7.1.0":
version "7.1.0"
resolved "https://registry.yarnpkg.com/@babel/helper-simple-access/-/helper-simple-access-7.1.0.tgz#65eeb954c8c245beaa4e859da6188f39d71e585c"
@@ -223,6 +295,14 @@
"@babel/template" "^7.1.0"
"@babel/types" "^7.0.0"
"@babel/helper-simple-access@^7.7.0":
version "7.7.0"
resolved "https://registry.yarnpkg.com/@babel/helper-simple-access/-/helper-simple-access-7.7.0.tgz#97a8b6c52105d76031b86237dc1852b44837243d"
integrity sha512-AJ7IZD7Eem3zZRuj5JtzFAptBw7pMlS3y8Qv09vaBWoFsle0d1kAn5Wq6Q9MyBXITPOKnxwkZKoAm4bopmv26g==
dependencies:
"@babel/template" "^7.7.0"
"@babel/types" "^7.7.0"
"@babel/helper-split-export-declaration@^7.0.0":
version "7.0.0"
resolved "https://registry.yarnpkg.com/@babel/helper-split-export-declaration/-/helper-split-export-declaration-7.0.0.tgz#3aae285c0311c2ab095d997b8c9a94cad547d813"
@@ -237,15 +317,22 @@
dependencies:
"@babel/types" "^7.4.4"
"@babel/helper-wrap-function@^7.1.0":
version "7.2.0"
resolved "https://registry.yarnpkg.com/@babel/helper-wrap-function/-/helper-wrap-function-7.2.0.tgz#c4e0012445769e2815b55296ead43a958549f6fa"
integrity sha512-o9fP1BZLLSrYlxYEYyl2aS+Flun5gtjTIG8iln+XuEzQTs0PLagAGSXUcqruJwD5fM48jzIEggCKpIfWTcR7pQ==
"@babel/helper-split-export-declaration@^7.7.0":
version "7.7.0"
resolved "https://registry.yarnpkg.com/@babel/helper-split-export-declaration/-/helper-split-export-declaration-7.7.0.tgz#1365e74ea6c614deeb56ebffabd71006a0eb2300"
integrity sha512-HgYSI8rH08neWlAH3CcdkFg9qX9YsZysZI5GD8LjhQib/mM0jGOZOVkoUiiV2Hu978fRtjtsGsW6w0pKHUWtqA==
dependencies:
"@babel/helper-function-name" "^7.1.0"
"@babel/template" "^7.1.0"
"@babel/traverse" "^7.1.0"
"@babel/types" "^7.2.0"
"@babel/types" "^7.7.0"
"@babel/helper-wrap-function@^7.7.0":
version "7.7.0"
resolved "https://registry.yarnpkg.com/@babel/helper-wrap-function/-/helper-wrap-function-7.7.0.tgz#15af3d3e98f8417a60554acbb6c14e75e0b33b74"
integrity sha512-sd4QjeMgQqzshSjecZjOp8uKfUtnpmCyQhKQrVJBBgeHAB/0FPi33h3AbVlVp07qQtMD4QgYSzaMI7VwncNK/w==
dependencies:
"@babel/helper-function-name" "^7.7.0"
"@babel/template" "^7.7.0"
"@babel/traverse" "^7.7.0"
"@babel/types" "^7.7.0"
"@babel/helpers@^7.6.2":
version "7.6.2"
@@ -280,13 +367,18 @@
resolved "https://registry.yarnpkg.com/@babel/parser/-/parser-7.6.4.tgz#cb9b36a7482110282d5cb6dd424ec9262b473d81"
integrity sha512-D8RHPW5qd0Vbyo3qb+YjO5nvUVRTXFLQ/FsDxJU2Nqz4uB5EnUN0ZQSEYpvTIbRuttig1XbHWU5oMeQwQSAA+A==
"@babel/plugin-proposal-async-generator-functions@^7.2.0":
version "7.2.0"
resolved "https://registry.yarnpkg.com/@babel/plugin-proposal-async-generator-functions/-/plugin-proposal-async-generator-functions-7.2.0.tgz#b289b306669dce4ad20b0252889a15768c9d417e"
integrity sha512-+Dfo/SCQqrwx48ptLVGLdE39YtWRuKc/Y9I5Fy0P1DDBB9lsAHpjcEJQt+4IifuSOSTLBKJObJqMvaO1pIE8LQ==
"@babel/parser@^7.7.0", "@babel/parser@^7.7.2":
version "7.7.2"
resolved "https://registry.yarnpkg.com/@babel/parser/-/parser-7.7.2.tgz#ea8334dc77416bfd9473eb470fd00d8245b3943b"
integrity sha512-DDaR5e0g4ZTb9aP7cpSZLkACEBdoLGwJDWgHtBhrGX7Q1RjhdoMOfexICj5cqTAtpowjGQWfcvfnQG7G2kAB5w==
"@babel/plugin-proposal-async-generator-functions@^7.7.0":
version "7.7.0"
resolved "https://registry.yarnpkg.com/@babel/plugin-proposal-async-generator-functions/-/plugin-proposal-async-generator-functions-7.7.0.tgz#83ef2d6044496b4c15d8b4904e2219e6dccc6971"
integrity sha512-ot/EZVvf3mXtZq0Pd0+tSOfGWMizqmOohXmNZg6LNFjHOV+wOPv7BvVYh8oPR8LhpIP3ye8nNooKL50YRWxpYA==
dependencies:
"@babel/helper-plugin-utils" "^7.0.0"
"@babel/helper-remap-async-to-generator" "^7.1.0"
"@babel/helper-remap-async-to-generator" "^7.7.0"
"@babel/plugin-syntax-async-generators" "^7.2.0"
"@babel/plugin-proposal-class-properties@^7.5.5":
@@ -297,10 +389,10 @@
"@babel/helper-create-class-features-plugin" "^7.5.5"
"@babel/helper-plugin-utils" "^7.0.0"
"@babel/plugin-proposal-dynamic-import@^7.5.0":
version "7.5.0"
resolved "https://registry.yarnpkg.com/@babel/plugin-proposal-dynamic-import/-/plugin-proposal-dynamic-import-7.5.0.tgz#e532202db4838723691b10a67b8ce509e397c506"
integrity sha512-x/iMjggsKTFHYC6g11PL7Qy58IK8H5zqfm9e6hu4z1iH2IRyAp9u9dL80zA6R76yFovETFLKz2VJIC2iIPBuFw==
"@babel/plugin-proposal-dynamic-import@^7.7.0":
version "7.7.0"
resolved "https://registry.yarnpkg.com/@babel/plugin-proposal-dynamic-import/-/plugin-proposal-dynamic-import-7.7.0.tgz#dc02a8bad8d653fb59daf085516fa416edd2aa7f"
integrity sha512-7poL3Xi+QFPC7sGAzEIbXUyYzGJwbc2+gSD0AkiC5k52kH2cqHdqxm5hNFfLW3cRSTcx9bN0Fl7/6zWcLLnKAQ==
dependencies:
"@babel/helper-plugin-utils" "^7.0.0"
"@babel/plugin-syntax-dynamic-import" "^7.2.0"
@@ -329,14 +421,13 @@
"@babel/helper-plugin-utils" "^7.0.0"
"@babel/plugin-syntax-optional-catch-binding" "^7.2.0"
"@babel/plugin-proposal-unicode-property-regex@^7.6.2":
version "7.6.2"
resolved "https://registry.yarnpkg.com/@babel/plugin-proposal-unicode-property-regex/-/plugin-proposal-unicode-property-regex-7.6.2.tgz#05413762894f41bfe42b9a5e80919bd575dcc802"
integrity sha512-NxHETdmpeSCtiatMRYWVJo7266rrvAC3DTeG5exQBIH/fMIUK7ejDNznBbn3HQl/o9peymRRg7Yqkx6PdUXmMw==
"@babel/plugin-proposal-unicode-property-regex@^7.7.0":
version "7.7.0"
resolved "https://registry.yarnpkg.com/@babel/plugin-proposal-unicode-property-regex/-/plugin-proposal-unicode-property-regex-7.7.0.tgz#549fe1717a1bd0a2a7e63163841cb37e78179d5d"
integrity sha512-mk34H+hp7kRBWJOOAR0ZMGCydgKMD4iN9TpDRp3IIcbunltxEY89XSimc6WbtSLCDrwcdy/EEw7h5CFCzxTchw==
dependencies:
"@babel/helper-create-regexp-features-plugin" "^7.7.0"
"@babel/helper-plugin-utils" "^7.0.0"
"@babel/helper-regex" "^7.4.4"
regexpu-core "^4.6.0"
"@babel/plugin-syntax-async-generators@^7.2.0":
version "7.2.0"
@@ -380,6 +471,13 @@
dependencies:
"@babel/helper-plugin-utils" "^7.0.0"
"@babel/plugin-syntax-top-level-await@^7.7.0":
version "7.7.0"
resolved "https://registry.yarnpkg.com/@babel/plugin-syntax-top-level-await/-/plugin-syntax-top-level-await-7.7.0.tgz#f5699549f50bbe8d12b1843a4e82f0a37bb65f4d"
integrity sha512-hi8FUNiFIY1fnUI2n1ViB1DR0R4QeK4iHcTlW6aJkrPoTdb8Rf1EMQ6GT3f67DDkYyWgew9DFoOZ6gOoEsdzTA==
dependencies:
"@babel/helper-plugin-utils" "^7.0.0"
"@babel/plugin-transform-arrow-functions@^7.2.0":
version "7.2.0"
resolved "https://registry.yarnpkg.com/@babel/plugin-transform-arrow-functions/-/plugin-transform-arrow-functions-7.2.0.tgz#9aeafbe4d6ffc6563bf8f8372091628f00779550"
@@ -387,14 +485,14 @@
dependencies:
"@babel/helper-plugin-utils" "^7.0.0"
"@babel/plugin-transform-async-to-generator@^7.5.0":
version "7.5.0"
resolved "https://registry.yarnpkg.com/@babel/plugin-transform-async-to-generator/-/plugin-transform-async-to-generator-7.5.0.tgz#89a3848a0166623b5bc481164b5936ab947e887e"
integrity sha512-mqvkzwIGkq0bEF1zLRRiTdjfomZJDV33AH3oQzHVGkI2VzEmXLpKKOBvEVaFZBJdN0XTyH38s9j/Kiqr68dggg==
"@babel/plugin-transform-async-to-generator@^7.7.0":
version "7.7.0"
resolved "https://registry.yarnpkg.com/@babel/plugin-transform-async-to-generator/-/plugin-transform-async-to-generator-7.7.0.tgz#e2b84f11952cf5913fe3438b7d2585042772f492"
integrity sha512-vLI2EFLVvRBL3d8roAMqtVY0Bm9C1QzLkdS57hiKrjUBSqsQYrBsMCeOg/0KK7B0eK9V71J5mWcha9yyoI2tZw==
dependencies:
"@babel/helper-module-imports" "^7.0.0"
"@babel/helper-module-imports" "^7.7.0"
"@babel/helper-plugin-utils" "^7.0.0"
"@babel/helper-remap-async-to-generator" "^7.1.0"
"@babel/helper-remap-async-to-generator" "^7.7.0"
"@babel/plugin-transform-block-scoped-functions@^7.2.0":
version "7.2.0"
@@ -411,18 +509,18 @@
"@babel/helper-plugin-utils" "^7.0.0"
lodash "^4.17.13"
"@babel/plugin-transform-classes@^7.5.5":
version "7.5.5"
resolved "https://registry.yarnpkg.com/@babel/plugin-transform-classes/-/plugin-transform-classes-7.5.5.tgz#d094299d9bd680a14a2a0edae38305ad60fb4de9"
integrity sha512-U2htCNK/6e9K7jGyJ++1p5XRU+LJjrwtoiVn9SzRlDT2KubcZ11OOwy3s24TjHxPgxNwonCYP7U2K51uVYCMDg==
"@babel/plugin-transform-classes@^7.7.0":
version "7.7.0"
resolved "https://registry.yarnpkg.com/@babel/plugin-transform-classes/-/plugin-transform-classes-7.7.0.tgz#b411ecc1b8822d24b81e5d184f24149136eddd4a"
integrity sha512-/b3cKIZwGeUesZheU9jNYcwrEA7f/Bo4IdPmvp7oHgvks2majB5BoT5byAql44fiNQYOPzhk2w8DbgfuafkMoA==
dependencies:
"@babel/helper-annotate-as-pure" "^7.0.0"
"@babel/helper-define-map" "^7.5.5"
"@babel/helper-function-name" "^7.1.0"
"@babel/helper-optimise-call-expression" "^7.0.0"
"@babel/helper-annotate-as-pure" "^7.7.0"
"@babel/helper-define-map" "^7.7.0"
"@babel/helper-function-name" "^7.7.0"
"@babel/helper-optimise-call-expression" "^7.7.0"
"@babel/helper-plugin-utils" "^7.0.0"
"@babel/helper-replace-supers" "^7.5.5"
"@babel/helper-split-export-declaration" "^7.4.4"
"@babel/helper-replace-supers" "^7.7.0"
"@babel/helper-split-export-declaration" "^7.7.0"
globals "^11.1.0"
"@babel/plugin-transform-computed-properties@^7.2.0":
@@ -439,14 +537,13 @@
dependencies:
"@babel/helper-plugin-utils" "^7.0.0"
"@babel/plugin-transform-dotall-regex@^7.6.2":
version "7.6.2"
resolved "https://registry.yarnpkg.com/@babel/plugin-transform-dotall-regex/-/plugin-transform-dotall-regex-7.6.2.tgz#44abb948b88f0199a627024e1508acaf8dc9b2f9"
integrity sha512-KGKT9aqKV+9YMZSkowzYoYEiHqgaDhGmPNZlZxX6UeHC4z30nC1J9IrZuGqbYFB1jaIGdv91ujpze0exiVK8bA==
"@babel/plugin-transform-dotall-regex@^7.7.0":
version "7.7.0"
resolved "https://registry.yarnpkg.com/@babel/plugin-transform-dotall-regex/-/plugin-transform-dotall-regex-7.7.0.tgz#c5c9ecacab3a5e0c11db6981610f0c32fd698b3b"
integrity sha512-3QQlF7hSBnSuM1hQ0pS3pmAbWLax/uGNCbPBND9y+oJ4Y776jsyujG2k0Sn2Aj2a0QwVOiOFL5QVPA7spjvzSA==
dependencies:
"@babel/helper-create-regexp-features-plugin" "^7.7.0"
"@babel/helper-plugin-utils" "^7.0.0"
"@babel/helper-regex" "^7.4.4"
regexpu-core "^4.6.0"
"@babel/plugin-transform-duplicate-keys@^7.5.0":
version "7.5.0"
@@ -470,12 +567,12 @@
dependencies:
"@babel/helper-plugin-utils" "^7.0.0"
"@babel/plugin-transform-function-name@^7.4.4":
version "7.4.4"
resolved "https://registry.yarnpkg.com/@babel/plugin-transform-function-name/-/plugin-transform-function-name-7.4.4.tgz#e1436116abb0610c2259094848754ac5230922ad"
integrity sha512-iU9pv7U+2jC9ANQkKeNF6DrPy4GBa4NWQtl6dHB4Pb3izX2JOEvDTFarlNsBj/63ZEzNNIAMs3Qw4fNCcSOXJA==
"@babel/plugin-transform-function-name@^7.7.0":
version "7.7.0"
resolved "https://registry.yarnpkg.com/@babel/plugin-transform-function-name/-/plugin-transform-function-name-7.7.0.tgz#0fa786f1eef52e3b7d4fc02e54b2129de8a04c2a"
integrity sha512-P5HKu0d9+CzZxP5jcrWdpe7ZlFDe24bmqP6a6X8BHEBl/eizAsY8K6LX8LASZL0Jxdjm5eEfzp+FIrxCm/p8bA==
dependencies:
"@babel/helper-function-name" "^7.1.0"
"@babel/helper-function-name" "^7.7.0"
"@babel/helper-plugin-utils" "^7.0.0"
"@babel/plugin-transform-literals@^7.2.0":
@@ -501,39 +598,39 @@
"@babel/helper-plugin-utils" "^7.0.0"
babel-plugin-dynamic-import-node "^2.3.0"
"@babel/plugin-transform-modules-commonjs@^7.6.0":
version "7.6.0"
resolved "https://registry.yarnpkg.com/@babel/plugin-transform-modules-commonjs/-/plugin-transform-modules-commonjs-7.6.0.tgz#39dfe957de4420445f1fcf88b68a2e4aa4515486"
integrity sha512-Ma93Ix95PNSEngqomy5LSBMAQvYKVe3dy+JlVJSHEXZR5ASL9lQBedMiCyVtmTLraIDVRE3ZjTZvmXXD2Ozw3g==
"@babel/plugin-transform-modules-commonjs@^7.7.0":
version "7.7.0"
resolved "https://registry.yarnpkg.com/@babel/plugin-transform-modules-commonjs/-/plugin-transform-modules-commonjs-7.7.0.tgz#3e5ffb4fd8c947feede69cbe24c9554ab4113fe3"
integrity sha512-KEMyWNNWnjOom8vR/1+d+Ocz/mILZG/eyHHO06OuBQ2aNhxT62fr4y6fGOplRx+CxCSp3IFwesL8WdINfY/3kg==
dependencies:
"@babel/helper-module-transforms" "^7.4.4"
"@babel/helper-module-transforms" "^7.7.0"
"@babel/helper-plugin-utils" "^7.0.0"
"@babel/helper-simple-access" "^7.1.0"
"@babel/helper-simple-access" "^7.7.0"
babel-plugin-dynamic-import-node "^2.3.0"
"@babel/plugin-transform-modules-systemjs@^7.5.0":
version "7.5.0"
resolved "https://registry.yarnpkg.com/@babel/plugin-transform-modules-systemjs/-/plugin-transform-modules-systemjs-7.5.0.tgz#e75266a13ef94202db2a0620977756f51d52d249"
integrity sha512-Q2m56tyoQWmuNGxEtUyeEkm6qJYFqs4c+XyXH5RAuYxObRNz9Zgj/1g2GMnjYp2EUyEy7YTrxliGCXzecl/vJg==
"@babel/plugin-transform-modules-systemjs@^7.7.0":
version "7.7.0"
resolved "https://registry.yarnpkg.com/@babel/plugin-transform-modules-systemjs/-/plugin-transform-modules-systemjs-7.7.0.tgz#9baf471213af9761c1617bb12fd278e629041417"
integrity sha512-ZAuFgYjJzDNv77AjXRqzQGlQl4HdUM6j296ee4fwKVZfhDR9LAGxfvXjBkb06gNETPnN0sLqRm9Gxg4wZH6dXg==
dependencies:
"@babel/helper-hoist-variables" "^7.4.4"
"@babel/helper-hoist-variables" "^7.7.0"
"@babel/helper-plugin-utils" "^7.0.0"
babel-plugin-dynamic-import-node "^2.3.0"
"@babel/plugin-transform-modules-umd@^7.2.0":
version "7.2.0"
resolved "https://registry.yarnpkg.com/@babel/plugin-transform-modules-umd/-/plugin-transform-modules-umd-7.2.0.tgz#7678ce75169f0877b8eb2235538c074268dd01ae"
integrity sha512-BV3bw6MyUH1iIsGhXlOK6sXhmSarZjtJ/vMiD9dNmpY8QXFFQTj+6v92pcfy1iqa8DeAfJFwoxcrS/TUZda6sw==
"@babel/plugin-transform-modules-umd@^7.7.0":
version "7.7.0"
resolved "https://registry.yarnpkg.com/@babel/plugin-transform-modules-umd/-/plugin-transform-modules-umd-7.7.0.tgz#d62c7da16670908e1d8c68ca0b5d4c0097b69966"
integrity sha512-u7eBA03zmUswQ9LQ7Qw0/ieC1pcAkbp5OQatbWUzY1PaBccvuJXUkYzoN1g7cqp7dbTu6Dp9bXyalBvD04AANA==
dependencies:
"@babel/helper-module-transforms" "^7.1.0"
"@babel/helper-module-transforms" "^7.7.0"
"@babel/helper-plugin-utils" "^7.0.0"
"@babel/plugin-transform-named-capturing-groups-regex@^7.6.3":
version "7.6.3"
resolved "https://registry.yarnpkg.com/@babel/plugin-transform-named-capturing-groups-regex/-/plugin-transform-named-capturing-groups-regex-7.6.3.tgz#aaa6e409dd4fb2e50b6e2a91f7e3a3149dbce0cf"
integrity sha512-jTkk7/uE6H2s5w6VlMHeWuH+Pcy2lmdwFoeWCVnvIrDUnB5gQqTVI8WfmEAhF2CDEarGrknZcmSFg1+bkfCoSw==
"@babel/plugin-transform-named-capturing-groups-regex@^7.7.0":
version "7.7.0"
resolved "https://registry.yarnpkg.com/@babel/plugin-transform-named-capturing-groups-regex/-/plugin-transform-named-capturing-groups-regex-7.7.0.tgz#358e6fd869b9a4d8f5cbc79e4ed4fc340e60dcaf"
integrity sha512-+SicSJoKouPctL+j1pqktRVCgy+xAch1hWWTMy13j0IflnyNjaoskj+DwRQFimHbLqO3sq2oN2CXMvXq3Bgapg==
dependencies:
regexpu-core "^4.6.0"
"@babel/helper-create-regexp-features-plugin" "^7.7.0"
"@babel/plugin-transform-new-target@^7.4.4":
version "7.4.4"
@@ -598,10 +695,10 @@
"@babel/helper-plugin-utils" "^7.0.0"
"@babel/plugin-syntax-jsx" "^7.2.0"
"@babel/plugin-transform-regenerator@^7.4.5":
version "7.4.5"
resolved "https://registry.yarnpkg.com/@babel/plugin-transform-regenerator/-/plugin-transform-regenerator-7.4.5.tgz#629dc82512c55cee01341fb27bdfcb210354680f"
integrity sha512-gBKRh5qAaCWntnd09S8QC7r3auLCqq5DI6O0DlfoyDjslSBVqBibrMdsqO+Uhmx3+BlOmE/Kw1HFxmGbv0N9dA==
"@babel/plugin-transform-regenerator@^7.7.0":
version "7.7.0"
resolved "https://registry.yarnpkg.com/@babel/plugin-transform-regenerator/-/plugin-transform-regenerator-7.7.0.tgz#f1b20b535e7716b622c99e989259d7dd942dd9cc"
integrity sha512-AXmvnC+0wuj/cFkkS/HFHIojxH3ffSXE+ttulrqWjZZRaUOonfJc60e1wSNT4rV8tIunvu/R3wCp71/tLAa9xg==
dependencies:
regenerator-transform "^0.14.0"
@@ -649,14 +746,13 @@
dependencies:
"@babel/helper-plugin-utils" "^7.0.0"
"@babel/plugin-transform-unicode-regex@^7.6.2":
version "7.6.2"
resolved "https://registry.yarnpkg.com/@babel/plugin-transform-unicode-regex/-/plugin-transform-unicode-regex-7.6.2.tgz#b692aad888a7e8d8b1b214be6b9dc03d5031f698"
integrity sha512-orZI6cWlR3nk2YmYdb0gImrgCUwb5cBUwjf6Ks6dvNVvXERkwtJWOQaEOjPiu0Gu1Tq6Yq/hruCZZOOi9F34Dw==
"@babel/plugin-transform-unicode-regex@^7.7.0":
version "7.7.0"
resolved "https://registry.yarnpkg.com/@babel/plugin-transform-unicode-regex/-/plugin-transform-unicode-regex-7.7.0.tgz#743d9bcc44080e3cc7d49259a066efa30f9187a3"
integrity sha512-RrThb0gdrNwFAqEAAx9OWgtx6ICK69x7i9tCnMdVrxQwSDp/Abu9DXFU5Hh16VP33Rmxh04+NGW28NsIkFvFKA==
dependencies:
"@babel/helper-create-regexp-features-plugin" "^7.7.0"
"@babel/helper-plugin-utils" "^7.0.0"
"@babel/helper-regex" "^7.4.4"
regexpu-core "^4.6.0"
"@babel/polyfill@^7.4.4":
version "7.6.0"
@@ -666,56 +762,57 @@
core-js "^2.6.5"
regenerator-runtime "^0.13.2"
"@babel/preset-env@7.6.3", "@babel/preset-env@^7.6.2":
version "7.6.3"
resolved "https://registry.yarnpkg.com/@babel/preset-env/-/preset-env-7.6.3.tgz#9e1bf05a2e2d687036d24c40e4639dc46cef2271"
integrity sha512-CWQkn7EVnwzlOdR5NOm2+pfgSNEZmvGjOhlCHBDq0J8/EStr+G+FvPEiz9B56dR6MoiUFjXhfE4hjLoAKKJtIQ==
"@babel/preset-env@7.7.1", "@babel/preset-env@^7.6.2":
version "7.7.1"
resolved "https://registry.yarnpkg.com/@babel/preset-env/-/preset-env-7.7.1.tgz#04a2ff53552c5885cf1083e291c8dd5490f744bb"
integrity sha512-/93SWhi3PxcVTDpSqC+Dp4YxUu3qZ4m7I76k0w73wYfn7bGVuRIO4QUz95aJksbS+AD1/mT1Ie7rbkT0wSplaA==
dependencies:
"@babel/helper-module-imports" "^7.0.0"
"@babel/helper-module-imports" "^7.7.0"
"@babel/helper-plugin-utils" "^7.0.0"
"@babel/plugin-proposal-async-generator-functions" "^7.2.0"
"@babel/plugin-proposal-dynamic-import" "^7.5.0"
"@babel/plugin-proposal-async-generator-functions" "^7.7.0"
"@babel/plugin-proposal-dynamic-import" "^7.7.0"
"@babel/plugin-proposal-json-strings" "^7.2.0"
"@babel/plugin-proposal-object-rest-spread" "^7.6.2"
"@babel/plugin-proposal-optional-catch-binding" "^7.2.0"
"@babel/plugin-proposal-unicode-property-regex" "^7.6.2"
"@babel/plugin-proposal-unicode-property-regex" "^7.7.0"
"@babel/plugin-syntax-async-generators" "^7.2.0"
"@babel/plugin-syntax-dynamic-import" "^7.2.0"
"@babel/plugin-syntax-json-strings" "^7.2.0"
"@babel/plugin-syntax-object-rest-spread" "^7.2.0"
"@babel/plugin-syntax-optional-catch-binding" "^7.2.0"
"@babel/plugin-syntax-top-level-await" "^7.7.0"
"@babel/plugin-transform-arrow-functions" "^7.2.0"
"@babel/plugin-transform-async-to-generator" "^7.5.0"
"@babel/plugin-transform-async-to-generator" "^7.7.0"
"@babel/plugin-transform-block-scoped-functions" "^7.2.0"
"@babel/plugin-transform-block-scoping" "^7.6.3"
"@babel/plugin-transform-classes" "^7.5.5"
"@babel/plugin-transform-classes" "^7.7.0"
"@babel/plugin-transform-computed-properties" "^7.2.0"
"@babel/plugin-transform-destructuring" "^7.6.0"
"@babel/plugin-transform-dotall-regex" "^7.6.2"
"@babel/plugin-transform-dotall-regex" "^7.7.0"
"@babel/plugin-transform-duplicate-keys" "^7.5.0"
"@babel/plugin-transform-exponentiation-operator" "^7.2.0"
"@babel/plugin-transform-for-of" "^7.4.4"
"@babel/plugin-transform-function-name" "^7.4.4"
"@babel/plugin-transform-function-name" "^7.7.0"
"@babel/plugin-transform-literals" "^7.2.0"
"@babel/plugin-transform-member-expression-literals" "^7.2.0"
"@babel/plugin-transform-modules-amd" "^7.5.0"
"@babel/plugin-transform-modules-commonjs" "^7.6.0"
"@babel/plugin-transform-modules-systemjs" "^7.5.0"
"@babel/plugin-transform-modules-umd" "^7.2.0"
"@babel/plugin-transform-named-capturing-groups-regex" "^7.6.3"
"@babel/plugin-transform-modules-commonjs" "^7.7.0"
"@babel/plugin-transform-modules-systemjs" "^7.7.0"
"@babel/plugin-transform-modules-umd" "^7.7.0"
"@babel/plugin-transform-named-capturing-groups-regex" "^7.7.0"
"@babel/plugin-transform-new-target" "^7.4.4"
"@babel/plugin-transform-object-super" "^7.5.5"
"@babel/plugin-transform-parameters" "^7.4.4"
"@babel/plugin-transform-property-literals" "^7.2.0"
"@babel/plugin-transform-regenerator" "^7.4.5"
"@babel/plugin-transform-regenerator" "^7.7.0"
"@babel/plugin-transform-reserved-words" "^7.2.0"
"@babel/plugin-transform-shorthand-properties" "^7.2.0"
"@babel/plugin-transform-spread" "^7.6.2"
"@babel/plugin-transform-sticky-regex" "^7.2.0"
"@babel/plugin-transform-template-literals" "^7.4.4"
"@babel/plugin-transform-typeof-symbol" "^7.2.0"
"@babel/plugin-transform-unicode-regex" "^7.6.2"
"@babel/types" "^7.6.3"
"@babel/plugin-transform-unicode-regex" "^7.7.0"
"@babel/types" "^7.7.1"
browserslist "^4.6.0"
core-js-compat "^3.1.1"
invariant "^2.2.2"
@@ -753,7 +850,7 @@
"@babel/parser" "^7.2.2"
"@babel/types" "^7.2.2"
"@babel/template@^7.4.4", "@babel/template@^7.6.0":
"@babel/template@^7.6.0":
version "7.6.0"
resolved "https://registry.yarnpkg.com/@babel/template/-/template-7.6.0.tgz#7f0159c7f5012230dad64cca42ec9bdb5c9536e6"
integrity sha512-5AEH2EXD8euCk446b7edmgFdub/qfH1SN6Nii3+fyXP807QRx9Q73A2N5hNwRRslC2H9sNzaFhsPubkS4L8oNQ==
@@ -762,6 +859,15 @@
"@babel/parser" "^7.6.0"
"@babel/types" "^7.6.0"
"@babel/template@^7.7.0":
version "7.7.0"
resolved "https://registry.yarnpkg.com/@babel/template/-/template-7.7.0.tgz#4fadc1b8e734d97f56de39c77de76f2562e597d0"
integrity sha512-OKcwSYOW1mhWbnTBgQY5lvg1Fxg+VyfQGjcBduZFljfc044J5iDlnDSfhQ867O17XHiSCxYHUxHg2b7ryitbUQ==
dependencies:
"@babel/code-frame" "^7.0.0"
"@babel/parser" "^7.7.0"
"@babel/types" "^7.7.0"
"@babel/traverse@^7.1.0", "@babel/traverse@^7.4.4", "@babel/traverse@^7.5.5", "@babel/traverse@^7.6.2", "@babel/traverse@^7.6.3":
version "7.6.3"
resolved "https://registry.yarnpkg.com/@babel/traverse/-/traverse-7.6.3.tgz#66d7dba146b086703c0fb10dd588b7364cec47f9"
@@ -777,19 +883,25 @@
globals "^11.1.0"
lodash "^4.17.13"
"@babel/types@^7.0.0", "@babel/types@^7.2.0", "@babel/types@^7.2.2", "@babel/types@^7.4.4", "@babel/types@^7.5.5", "@babel/types@^7.6.0", "@babel/types@^7.6.1", "@babel/types@^7.6.3":
version "7.6.3"
resolved "https://registry.yarnpkg.com/@babel/types/-/types-7.6.3.tgz#3f07d96f854f98e2fbd45c64b0cb942d11e8ba09"
integrity sha512-CqbcpTxMcpuQTMhjI37ZHVgjBkysg5icREQIEZ0eG1yCNwg3oy+5AaLiOKmjsCj6nqOsa6Hf0ObjRVwokb7srA==
"@babel/traverse@^7.7.0":
version "7.7.2"
resolved "https://registry.yarnpkg.com/@babel/traverse/-/traverse-7.7.2.tgz#ef0a65e07a2f3c550967366b3d9b62a2dcbeae09"
integrity sha512-TM01cXib2+rgIZrGJOLaHV/iZUAxf4A0dt5auY6KNZ+cm6aschuJGqKJM3ROTt3raPUdIDk9siAufIFEleRwtw==
dependencies:
esutils "^2.0.2"
"@babel/code-frame" "^7.5.5"
"@babel/generator" "^7.7.2"
"@babel/helper-function-name" "^7.7.0"
"@babel/helper-split-export-declaration" "^7.7.0"
"@babel/parser" "^7.7.2"
"@babel/types" "^7.7.2"
debug "^4.1.0"
globals "^11.1.0"
lodash "^4.17.13"
to-fast-properties "^2.0.0"
"@babel/types@^7.7.0":
version "7.7.1"
resolved "https://registry.yarnpkg.com/@babel/types/-/types-7.7.1.tgz#8b08ea368f2baff236613512cf67109e76285827"
integrity sha512-kN/XdANDab9x1z5gcjDc9ePpxexkt+1EQ2MQUiM4XnMvQfvp87/+6kY4Ko2maLXH+tei/DgJ/ybFITeqqRwDiA==
"@babel/types@^7.0.0", "@babel/types@^7.2.2", "@babel/types@^7.4.4", "@babel/types@^7.5.5", "@babel/types@^7.6.0", "@babel/types@^7.6.1", "@babel/types@^7.6.3", "@babel/types@^7.7.0", "@babel/types@^7.7.1", "@babel/types@^7.7.2":
version "7.7.2"
resolved "https://registry.yarnpkg.com/@babel/types/-/types-7.7.2.tgz#550b82e5571dcd174af576e23f0adba7ffc683f7"
integrity sha512-YTf6PXoh3+eZgRCBzzP25Bugd2ngmpQVrk7kXX0i5N9BO7TFBtIgZYs7WtxtOGs8e6A4ZI7ECkbBCEHeXocvOA==
dependencies:
esutils "^2.0.2"
lodash "^4.17.13"
+118 -504
View File
File diff suppressed because it is too large. Load diff