Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commite753d9c

Browse files
committed
refactor!: disable shortEmits in Vue 3.3
1 parent1ec1b8b commite753d9c

File tree

3 files changed

+10
-2
lines changed

3 files changed

+10
-2
lines changed

‎docs/macros/short-emits.md‎

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,8 @@
44

55
Simplify the definition of emits.
66

7+
For Vue >= 3.3, this feature will be turned off by default.
8+
79
| Features| Supported|
810
| :--------:| :----------------:|
911
| Vue 3|:white_check_mark:|

‎docs/zh-CN/macros/short-emits.md‎

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,9 @@
22

33
<small>稳定性: <codeclass="!text-green-600">稳定</code></small>
44

5-
简化`emits` 的定义
5+
简化`emits` 的定义。
6+
7+
在 Vue >= 3.3 中,此功能将默认关闭。
68

79
| 特性| 功能|
810
| :--------:| :----------------:|

‎packages/macros/src/index.ts‎

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -164,7 +164,11 @@ function resolveOptions({
164164
root,
165165
}),
166166
setupSFC:resolveSubOptions<'setupSFC'>(setupSFC,{ version}),
167-
shortEmits:resolveSubOptions<'shortEmits'>(shortEmits,{ version}),
167+
shortEmits:resolveSubOptions<'shortEmits'>(
168+
shortEmits,
169+
{ version},
170+
version<3.3
171+
),
168172
singleDefine:resolveSubOptions<'singleDefine'>(singleDefine,{
169173
isProduction,
170174
version,

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp