Skip to content

Commit e4f5fff

Browse files
authored
fix: skip checking private properties of typeParameters (#443)
1 parent f51f7b7 commit e4f5fff

File tree

1 file changed

+7
-1
lines changed

1 file changed

+7
-1
lines changed

packages/plugin-vue/src/handleHotUpdate.ts

+7-1
Original file line numberDiff line numberDiff line change
@@ -259,7 +259,6 @@ function isEqualAst(prev?: t.Statement[], next?: t.Statement[]): boolean {
259259
return prev === next
260260
}
261261

262-
// deep equal, but ignore start/end/loc/range/leadingComments/trailingComments/innerComments
263262
if (prev.length !== next.length) {
264263
return false
265264
}
@@ -268,6 +267,7 @@ function isEqualAst(prev?: t.Statement[], next?: t.Statement[]): boolean {
268267
const prevNode = prev[i]
269268
const nextNode = next[i]
270269
if (
270+
// deep equal, but ignore start/end/loc/range/leadingComments/trailingComments/innerComments
271271
!deepEqual(prevNode, nextNode, [
272272
'start',
273273
'end',
@@ -276,6 +276,12 @@ function isEqualAst(prev?: t.Statement[], next?: t.Statement[]): boolean {
276276
'leadingComments',
277277
'trailingComments',
278278
'innerComments',
279+
// https://github.com/vuejs/core/issues/11923
280+
// avoid comparing the following properties of typeParameters
281+
// as it may be imported from 3rd lib and complex to compare
282+
'_ownerScope',
283+
'_resolvedReference',
284+
'_resolvedElements'
279285
])
280286
) {
281287
return false

0 commit comments

Comments
 (0)