Skip to content

Commit 640b26d

Browse files
committed
fix extend exclude names
1 parent 20f9766 commit 640b26d

File tree

3 files changed

+4
-3
lines changed

3 files changed

+4
-3
lines changed

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "vue-facing-decorator",
3-
"version": "2.1.14",
3+
"version": "2.1.15",
44
"description": "Vue typescript class and decorator based component.",
55
"main": "dist/index.js",
66
"module": "dist/esm/index.js",

src/utils.ts

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -126,7 +126,6 @@ export function getSuperSlot(obj: any) {
126126
export function excludeNames(names: string[], slot: Slot) {
127127
return names.filter(name => {
128128
let currSlot: Slot | null = slot
129-
130129
while (currSlot != null) {
131130
for (const mapName of currSlot.names.keys()) {
132131
if (['watch', 'hooks'].includes(mapName)) {
@@ -137,7 +136,7 @@ export function excludeNames(names: string[], slot: Slot) {
137136
return false
138137
}
139138
}
140-
currSlot = getSuperSlot(slot.master)
139+
currSlot = getSuperSlot(currSlot.master)
141140
}
142141

143142
return true

test/feature/componentExtends.ts

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,7 @@
22
import { expect } from 'chai';
33
import 'mocha';
44
import { Component, ComponentBase, Base } from '../../dist'
5+
56
@ComponentBase({
67
name:'ComponentBase'
78
})
@@ -11,6 +12,7 @@ class Sup extends Base {
1112
return 'methodSup value'
1213
}
1314
}
15+
1416
@Component
1517
export class Comp extends Sup {
1618
dataComp = 'dataComp value'

0 commit comments

Comments
 (0)