vue-facing-decorator
Advanced tools
Comparing version 2.0.4 to 2.1.0
@@ -13,4 +13,5 @@ export { Component, ComponentBase } from './component'; | ||
} | ||
export declare function TSX<Properties extends {}>(): <C extends new () => ComponentPublicInstance & BaseTypeIdentify>(cons: C) => new () => Omit<ComponentPublicInstance<InstanceType<C>["$props"] & Properties, {}, {}, {}, {}, {}, InstanceType<C>["$props"] & Properties, {}, false, import("vue").ComponentOptionsBase<any, any, any, any, any, any, any, any, any, {}>>, keyof Properties> & InstanceType<C>; | ||
export declare const Base: new () => ComponentPublicInstance & BaseTypeIdentify; | ||
export declare const Vue: new () => ComponentPublicInstance & BaseTypeIdentify; | ||
//# sourceMappingURL=index.d.ts.map |
"use strict"; | ||
Object.defineProperty(exports, "__esModule", { value: true }); | ||
exports.Vue = exports.Base = exports.VModel = exports.Emit = exports.Inject = exports.Prop = exports.Watch = exports.Ref = exports.ComponentBase = exports.Component = void 0; | ||
exports.Vue = exports.Base = exports.TSX = exports.VModel = exports.Emit = exports.Inject = exports.Prop = exports.Watch = exports.Ref = exports.ComponentBase = exports.Component = void 0; | ||
var component_1 = require("./component"); | ||
@@ -20,2 +20,8 @@ Object.defineProperty(exports, "Component", { enumerable: true, get: function () { return component_1.Component; } }); | ||
const IdentifySymbol = Symbol('vue-facing-decorator-identify'); | ||
function TSX() { | ||
return function (cons) { | ||
return cons; | ||
}; | ||
} | ||
exports.TSX = TSX; | ||
exports.Base = class { | ||
@@ -22,0 +28,0 @@ }; |
import { Cons, OptionBuilder } from '../component'; | ||
export declare const LifecycleNames: readonly ["beforeCreate", "created", "beforeMount", "mounted", "beforeUpdate", "updated", "activated", "deactivated", "beforeDestroy", "beforeUnmount", "destroyed", "unmounted", "renderTracked", "renderTriggered", "errorCaptured", "serverPrefetch"]; | ||
export declare const LifecycleNames: readonly ["beforeCreate", "created", "beforeMount", "mounted", "beforeUpdate", "updated", "activated", "deactivated", "beforeDestroy", "beforeUnmount", "destroyed", "unmounted", "renderTracked", "renderTriggered", "errorCaptured", "serverPrefetch", "render"]; | ||
export declare function build(cons: Cons, optionBuilder: OptionBuilder): void; | ||
//# sourceMappingURL=methodsAndLifecycle.d.ts.map |
@@ -22,3 +22,4 @@ "use strict"; | ||
"errorCaptured", | ||
"serverPrefetch" | ||
"serverPrefetch", | ||
"render" | ||
]; | ||
@@ -25,0 +26,0 @@ function build(cons, optionBuilder) { |
{ | ||
"name": "vue-facing-decorator", | ||
"version": "2.0.4", | ||
"version": "2.1.0", | ||
"description": "Vue typescript class and decorator based component.", | ||
@@ -5,0 +5,0 @@ "main": "dist/index.js", |
@@ -10,4 +10,3 @@ | ||
import type { | ||
ComponentPublicInstance, | ||
ComponentOptions | ||
ComponentPublicInstance | ||
} from 'vue' | ||
@@ -18,2 +17,9 @@ const IdentifySymbol = Symbol('vue-facing-decorator-identify') | ||
} | ||
export function TSX<Properties extends {}>() { | ||
return function <C extends { new(): ComponentPublicInstance & BaseTypeIdentify }>(cons: C) { | ||
return cons as unknown as { | ||
new(): Omit<ComponentPublicInstance<(InstanceType<C>['$props']) & Properties>, keyof Properties> & InstanceType<C>//& ComponentPublicInstance & BaseTypeIdentify | ||
} | ||
} | ||
} | ||
@@ -23,4 +29,2 @@ export const Base = class { } as { | ||
} | ||
export const Vue = Base |
@@ -20,3 +20,4 @@ import { makeObject, obtainSlot } from '../utils' | ||
"errorCaptured", | ||
"serverPrefetch" | ||
"serverPrefetch", | ||
"render" | ||
] as const | ||
@@ -23,0 +24,0 @@ |
@@ -15,2 +15,4 @@ import './internal/utils' | ||
import './feature/componentExtends' | ||
import './feature/extends' | ||
import './feature/extends' | ||
import './tsx/attributeTypes' |
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
96331
92
1936