Skip to content

Commit

Permalink
chore: bump Prettier to 2.7 (#5491)
Browse files Browse the repository at this point in the history
  • Loading branch information
JoshuaKGoldberg committed Aug 17, 2022
1 parent 68c937e commit faaac27
Show file tree
Hide file tree
Showing 8 changed files with 19 additions and 25 deletions.
6 changes: 0 additions & 6 deletions .prettierignore
Expand Up @@ -12,12 +12,6 @@ packages/eslint-plugin/src/configs/*.json
CONTRIBUTORS.md
packages/ast-spec/src/*/*/fixtures/_error_/*/fixture.ts

# Syntax not yet supported
packages/scope-manager/tests/fixtures/type-declaration/type-query-with-parameters.ts
packages/scope-manager/tests/fixtures/type-declaration/infer-type-constraint.ts
packages/scope-manager/tests/fixtures/instantiation-expressions/type-arguments1.ts
packages/scope-manager/tests/fixtures/instantiation-expressions/type-arguments2.ts

# Ignore CHANGELOG.md files to avoid issues with automated release job
CHANGELOG.md

Expand Down
4 changes: 2 additions & 2 deletions package.json
Expand Up @@ -95,7 +95,7 @@
"make-dir": "^3.1.0",
"markdownlint-cli": "^0.31.1",
"ncp": "^2.0.0",
"prettier": "2.5.1",
"prettier": "2.7.1",
"pretty-format": "^28.1.0",
"rimraf": "^3.0.2",
"tmp": "^0.2.1",
Expand All @@ -104,7 +104,7 @@
"typescript": ">=3.3.1 <4.8.0"
},
"resolutions": {
"typescript": "4.7.2",
"typescript": "4.7.4",
"@types/node": "^17.0.31",
"pretty-format": "^28.1.0",
"//": "Pin jest to v28 across the repo",
Expand Down
Expand Up @@ -112,7 +112,7 @@ class Foo {
'const x = new Set<any>();',
'const x = { y: 1 };',
'const x = { y = 1 };',
'const x = { y(); };',
noFormat`const x = { y(); };`,
'const x: { y: number } = { y: 1 };',
'const x = [...[1, 2, 3]];',
'const [{ [`x${1}`]: x }] = [{ [`x`]: 1 }] as [{ [`x`]: any }];',
Expand Down
@@ -1,5 +1,5 @@
import { TSESLint } from '@typescript-eslint/utils';
import { RuleTester, getFixturesRootDir } from '../RuleTester';
import { RuleTester, getFixturesRootDir, noFormat } from '../RuleTester';
import rule from '../../src/rules/prefer-readonly-parameter-types';
import {
InferMessageIdsTypeFromRule,
Expand Down Expand Up @@ -288,7 +288,7 @@ ruleTester.run('prefer-readonly-parameter-types', rule, {
new (arg: readonly string[]): void;
}
`, // TSConstructSignatureDeclaration
'const x = { foo(arg: readonly string[]): void; };', // TSEmptyBodyFunctionExpression
noFormat`const x = { foo(arg: readonly string[]): void; };`, // TSEmptyBodyFunctionExpression
'function foo(arg: readonly string[]);', // TSDeclareFunction
'type Foo = (arg: readonly string[]) => void;', // TSFunctionType
`
Expand Down Expand Up @@ -627,7 +627,7 @@ ruleTester.run('prefer-readonly-parameter-types', rule, {
},
{
// TSEmptyBodyFunctionExpression
code: 'const x = { foo(arg: string[]): void; };',
code: noFormat`const x = { foo(arg: string[]): void; };`,
errors: [
{
messageId: 'shouldBeReadonly',
Expand Down
@@ -1,9 +1,9 @@
class Foo<T> {
value: T
value: T;
}

class Bar<T> {
foo = Foo<T>
foo = Foo<T>;
}

new Bar()
new Bar();
2 changes: 1 addition & 1 deletion tests/integration/fixtures/vue-sfc/Hello.vue
Expand Up @@ -3,7 +3,7 @@
<div>
<div>
<!-- !!!!! expected error !!!!! -->
Hello {{ (name as any) }}{{ exclamationMarks }}
Hello {{ name as any }}{{ exclamationMarks }}
</div>
<button @click="decrement">-</button>
<button @click="increment">+</button>
Expand Down
2 changes: 1 addition & 1 deletion tests/integration/tests/__snapshots__/vue-sfc.test.ts.snap
Expand Up @@ -21,7 +21,7 @@ Array [
<div>
<div>
<!-- !!!!! expected error !!!!! -->
Hello {{ (name as any) }}{{ exclamationMarks }}
Hello {{ name as any }}{{ exclamationMarks }}
</div>
<button @click=\\"decrement\\">-</button>
<button @click=\\"increment\\">+</button>
Expand Down
16 changes: 8 additions & 8 deletions yarn.lock
Expand Up @@ -11992,10 +11992,10 @@ prepend-http@^2.0.0:
resolved "https://registry.yarnpkg.com/prepend-http/-/prepend-http-2.0.0.tgz#e92434bfa5ea8c19f41cdfd401d741a3c819d897"
integrity sha1-6SQ0v6XqjBn0HN/UAddBo8gZ2Jc=

prettier@*, prettier@2.5.1:
version "2.5.1"
resolved "https://registry.yarnpkg.com/prettier/-/prettier-2.5.1.tgz#fff75fa9d519c54cf0fce328c1017d94546bc56a"
integrity sha512-vBZcPRUR5MZJwoyi3ZoyQlc1rXeEck8KgeC9AwwOn+exuxLxq5toTRDTSaVrXHxelDMHy9zlicw8u66yxoSUFg==
prettier@*, prettier@2.7.1:
version "2.7.1"
resolved "https://registry.yarnpkg.com/prettier/-/prettier-2.7.1.tgz#e235806850d057f97bb08368a4f7d899f7760c64"
integrity sha512-ujppO+MkdPqoVINuDFDRLClm7D78qbDt0/NR+wp5FqEZOoTNAjPHWj17QRhu7geIHJfcNhRk1XVQmF8Bp3ye+g==

pretty-bytes@^5.6.0:
version "5.6.0"
Expand Down Expand Up @@ -14066,10 +14066,10 @@ typedarray@^0.0.6:
resolved "https://registry.yarnpkg.com/typedarray/-/typedarray-0.0.6.tgz#867ac74e3864187b1d3d47d996a78ec5c8830777"
integrity sha1-hnrHTjhkGHsdPUfZlqeOxciDB3c=

typescript@*, typescript@4.7.2, "typescript@>=3.3.1 <4.8.0", typescript@^4.5.3, typescript@^4.5.5, typescript@~4.7.4:
version "4.7.2"
resolved "https://registry.yarnpkg.com/typescript/-/typescript-4.7.2.tgz#1f9aa2ceb9af87cca227813b4310fff0b51593c4"
integrity sha512-Mamb1iX2FDUpcTRzltPxgWMKy3fhg0TN378ylbktPGPK/99KbDtMQ4W1hwgsbPAsG3a0xKa1vmw4VKZQbkvz5A==
typescript@*, typescript@4.7.4, "typescript@>=3.3.1 <4.8.0", typescript@^4.5.3, typescript@^4.5.5, typescript@~4.7.4:
version "4.7.4"
resolved "https://registry.yarnpkg.com/typescript/-/typescript-4.7.4.tgz#1a88596d1cf47d59507a1bcdfb5b9dfe4d488235"
integrity sha512-C0WQT0gezHuw6AdY1M2jxUO83Rjf0HP7Sk1DtXj6j1EwkQNZrHAg2XPWlq62oqEhYvONq5pkC2Y9oPljWToLmQ==

ua-parser-js@^0.7.30:
version "0.7.31"
Expand Down

0 comments on commit faaac27

Please sign in to comment.