]> git.ipfire.org Git - thirdparty/vuejs/core.git/commitdiff
chore: fix typos in defineOptions (#8277)
authorCédric Exbrayat <cexbrayat@users.noreply.github.com>
Thu, 11 May 2023 11:34:27 +0000 (13:34 +0200)
committerGitHub <noreply@github.com>
Thu, 11 May 2023 11:34:27 +0000 (19:34 +0800)
packages/compiler-sfc/__tests__/compileScript/defineOptions.spec.ts
packages/compiler-sfc/src/script/defineProps.ts
packages/runtime-core/src/apiSetupHelpers.ts

index 5337a53917c567d527b4a6d2cba06e81f107438b..e4f50be38f7a21d6a91b5243316671f80e69a1be 100644 (file)
@@ -28,7 +28,7 @@ describe('defineOptions()', () => {
     expect(content).not.toMatch('defineOptions')
   })
 
-  it('should emit an error with two defineProps', () => {
+  it('should emit an error with two defineOptions', () => {
     expect(() =>
       compile(`
       <script setup>
index dde415c21a1078905b65d7189458b4a8a2bff65f..2a0882284fbe6642af5e3e280319c84da8d62d71 100644 (file)
@@ -325,7 +325,7 @@ function genDestructuredDefaultValue(
     // If the default value is a function or is an identifier referencing
     // external value, skip factory wrap. This is needed when using
     // destructure w/ runtime declaration since we cannot safely infer
-    // whether tje expected runtime prop type is `Function`.
+    // whether the expected runtime prop type is `Function`.
     const needSkipFactory =
       !inferredType &&
       (isFunctionType(unwrapped) || unwrapped.type === 'Identifier')
index 554115240b3146c22104d63f382fb111c8e6085b..3ad330a1c27ed2b18c753bfe29871a433aa86335 100644 (file)
@@ -176,7 +176,7 @@ export function defineExpose<
 /**
  * Vue `<script setup>` compiler macro for declaring a component's additional
  * options. This should be used only for options that cannot be expressed via
- * Composition API - e.g. `inhertiAttrs`.
+ * Composition API - e.g. `inheritAttrs`.
  *
  * @see {@link https://vuejs.org/api/sfc-script-setup.html#defineoptions}
  */