Explorar o código

fix RenderContext (#4099)

Kaorun343 %!s(int64=9) %!d(string=hai) anos
pai
achega
887ec90d14
Modificáronse 2 ficheiros con 2 adicións e 2 borrados
  1. 1 1
      types/options.d.ts
  2. 1 1
      types/test/options-test.ts

+ 1 - 1
types/options.d.ts

@@ -55,7 +55,7 @@ export interface FunctionalComponentOptions {
 export interface RenderContext {
   props: any;
   children: VNode[];
-  slots: any;
+  slots(): any;
   data: VNodeData;
   parent: Vue;
 }

+ 1 - 1
types/test/options-test.ts

@@ -166,7 +166,7 @@ Vue.component('functional-component', {
   render(createElement, context) {
     context.props;
     context.children;
-    context.slots;
+    context.slots();
     context.data;
     context.parent;
     return createElement("div", {}, context.children);