]> git.ipfire.org Git - thirdparty/vuejs/core.git/commitdiff
chore: apply format
authorAnthony Fu <anthonyfu117@hotmail.com>
Thu, 12 Jan 2023 12:02:33 +0000 (13:02 +0100)
committerAnthony Fu <anthonyfu117@hotmail.com>
Thu, 12 Jan 2023 12:02:33 +0000 (13:02 +0100)
.eslintrc.js
package.json
test-dts/defineComponent.test-d.tsx
test-dts/defineCustomElement.test-d.ts
test-dts/setupHelpers.test-d.ts

index cdbb1dffd91585a54651f3839445f0adc6e73e19..c0282ebd8173c162d284b36d2607531d831da8d4 100644 (file)
@@ -6,7 +6,7 @@ module.exports = {
   parserOptions: {
     sourceType: 'module'
   },
-  plugins: ["jest"],
+  plugins: ['jest'],
   rules: {
     'no-debugger': 'error',
     'no-unused-vars': [
@@ -72,7 +72,12 @@ module.exports = {
     },
     // Node scripts
     {
-      files: ['scripts/**', './*.js', 'packages/**/index.js', 'packages/size-check/**'],
+      files: [
+        'scripts/**',
+        './*.js',
+        'packages/**/index.js',
+        'packages/size-check/**'
+      ],
       rules: {
         'no-restricted-globals': 'off',
         'no-restricted-syntax': 'off'
index 27dcc42903a82f7ff4ec7ffca4a8c32a7db821c3..53bd782547d45933b205eccfcbc730d4b7ff7aae 100644 (file)
@@ -9,8 +9,8 @@
     "size-global": "node scripts/build.js vue runtime-dom -f global -p",
     "size-baseline": "node scripts/build.js runtime-dom runtime-core reactivity shared -f esm-bundler && cd packages/size-check && vite build && node brotli",
     "lint": "eslint --cache --ext .ts packages/*/{src,__tests__}/**.ts",
-    "format": "prettier --write --cache --parser typescript \"packages/**/*.ts?(x)\"",
-    "format-check": "prettier --check --cache --parser typescript \"packages/**/*.ts?(x)\"",
+    "format": "prettier --write --cache --parser typescript \"**/*.[tj]s?(x)\"",
+    "format-check": "prettier --check --cache --parser typescript \"**/*.[tj]s?(x)\"",
     "test": "run-s \"test-unit {@}\" \"test-e2e {@}\"",
     "test-unit": "jest --filter ./scripts/filter-unit.js",
     "test-e2e": "node scripts/build.js vue -f global -d && jest --filter ./scripts/filter-e2e.js --runInBand",
index 208501e4286204e0c9b2b10b874f3812fcd857fc..1ad6ee1f38f6f13738309a09251c003080151a93 100644 (file)
@@ -1041,13 +1041,13 @@ describe('inject', () => {
     },
     inject: {
       foo: 'foo',
-      bar: 'bar',
+      bar: 'bar'
     },
     created() {
       expectType<unknown>(this.foo)
       expectType<unknown>(this.bar)
       //  @ts-expect-error
-      expectError(this.foobar = 1)
+      expectError((this.foobar = 1))
     }
   })
 
@@ -1059,7 +1059,7 @@ describe('inject', () => {
       expectType<unknown>(this.foo)
       expectType<unknown>(this.bar)
       //  @ts-expect-error
-      expectError(this.foobar = 1)
+      expectError((this.foobar = 1))
     }
   })
 
@@ -1073,13 +1073,13 @@ describe('inject', () => {
       bar: {
         from: 'pbar',
         default: 'bar'
-      },
+      }
     },
     created() {
       expectType<unknown>(this.foo)
       expectType<unknown>(this.bar)
       //  @ts-expect-error
-      expectError(this.foobar = 1)
+      expectError((this.foobar = 1))
     }
   })
 
@@ -1088,9 +1088,9 @@ describe('inject', () => {
     props: ['a', 'b'],
     created() {
       //  @ts-expect-error
-      expectError(this.foo = 1)
+      expectError((this.foo = 1))
       //  @ts-expect-error
-      expectError(this.bar = 1)
+      expectError((this.bar = 1))
     }
   })
 })
index 8e60ac1c1df24e772d1da788c3327d6db9a87ddf..7433f23c14f25345399293a2dab21c6898efdf5c 100644 (file)
@@ -8,13 +8,13 @@ describe('inject', () => {
     },
     inject: {
       foo: 'foo',
-      bar: 'bar',
+      bar: 'bar'
     },
     created() {
       expectType<unknown>(this.foo)
       expectType<unknown>(this.bar)
       //  @ts-expect-error
-      expectError(this.foobar = 1)
+      expectError((this.foobar = 1))
     }
   })
 
@@ -26,7 +26,7 @@ describe('inject', () => {
       expectType<unknown>(this.foo)
       expectType<unknown>(this.bar)
       //  @ts-expect-error
-      expectError(this.foobar = 1)
+      expectError((this.foobar = 1))
     }
   })
 
@@ -40,13 +40,13 @@ describe('inject', () => {
       bar: {
         from: 'pfoo',
         default: 'bar'
-      },
+      }
     },
     created() {
       expectType<unknown>(this.foo)
       expectType<unknown>(this.bar)
       //  @ts-expect-error
-      expectError(this.foobar = 1)
+      expectError((this.foobar = 1))
     }
   })
 
@@ -55,9 +55,9 @@ describe('inject', () => {
     props: ['a', 'b'],
     created() {
       //  @ts-expect-error
-      expectError(this.foo = 1)
+      expectError((this.foo = 1))
       //  @ts-expect-error
-      expectError(this.bar = 1)
+      expectError((this.bar = 1))
     }
   })
-})
\ No newline at end of file
+})
index d099d37441d6419f7bbe4b47bdbdc2abee65a21e..e8066e4e5b783c9980ccd5bfdca684bb930b15c7 100644 (file)
@@ -70,7 +70,7 @@ describe('defineProps w/ union type declaration + withDefaults', () => {
       union1: 123,
       union2: () => [123],
       union3: () => ({ x: 123 }),
-      union4: () => 123,
+      union4: () => 123
     }
   )
 })