Skip to content
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.

Commit 55abcc0

Browse files
committedFeb 7, 2024
feat(vue3): exclude directives from setup state
1 parent d983fcc commit 55abcc0

File tree

1 file changed

+4
-3
lines changed
  • packages/app-backend-vue3/src/components

1 file changed

+4
-3
lines changed
 

‎packages/app-backend-vue3/src/components/data.ts

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -193,9 +193,10 @@ function processSetupState(instance) {
193193
let result: any
194194

195195
let isOther = typeof value === 'function'
196-
|| typeof value?.render === 'function'
197-
|| typeof value?.__asyncLoader === 'function'
198-
|| (typeof value === 'object' && value && ('setup' in value || 'props' in value))
196+
|| typeof value?.render === 'function' // Components
197+
|| typeof value?.__asyncLoader === 'function' // Components
198+
|| (typeof value === 'object' && value && ('setup' in value || 'props' in value)) // Components
199+
|| /^v[A-Z]/.test(key) // Directives
199200

200201
if (rawData) {
201202
const info = getSetupStateInfo(rawData)

0 commit comments

Comments
 (0)
Please sign in to comment.