We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent c662fe0 commit ebe2729Copy full SHA for ebe2729
types/test/vue-test.ts
@@ -1,6 +1,8 @@
1
import Vue = require("../index");
2
3
class Test extends Vue {
4
+ a: number;
5
+
6
testProperties() {
7
this.$data;
8
this.$el;
@@ -37,7 +39,7 @@ class Test extends Vue {
37
39
immediate: true,
38
40
deep: false
41
})();
- this.$watch(() => {}, (val: number) => {});
42
+ this.$watch(() => this.a, (val: number) => {});
43
this.$on("", () => {});
44
this.$once("", () => {});
45
this.$off("", () => {});
types/vue.d.ts
@@ -55,7 +55,7 @@ export declare class Vue {
55
options?: WatchOptions
56
): (() => void);
57
$watch<T>(
58
- expOrFn: () => T,
+ expOrFn: (this: this) => T,
59
callback: WatchHandler<this, T>,
60
61
0 commit comments