Skip to content

Commit

Permalink
@Render added functional option
Browse files Browse the repository at this point in the history
  • Loading branch information
joon610 committed Aug 23, 2019
1 parent 2a472fe commit 82109e3
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 3 deletions.
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "vue-corator",
"version": "1.6.5",
"version": "1.6.6",
"description": "this is TypeScript Vue decorator.",
"main": "lib/vue-corator.d.ts",
"module": "lib/vue-corator.js",
Expand Down
5 changes: 3 additions & 2 deletions src/vue-corator.ts
Original file line number Diff line number Diff line change
Expand Up @@ -57,6 +57,7 @@ export function Render(componentName?: string) {
const props = parameta.split(',');
const newComponent = {
props,
functional: true,
render(createElement: any) {
return compiledTemplate.render.call(this, createElement);
}
Expand All @@ -66,8 +67,8 @@ export function Render(componentName?: string) {
options.components[componentName || key] = newComponent;
})(target, key);
};
}

}
export function ScopedId(key?: string) {
return createDecorator((options, k) => {
options.computed = options.computed || {};
Expand Down

0 comments on commit 82109e3

Please sign in to comment.