showing results for - "track window resize in vue"
Lynn
19 Jan 2021
1created() {
2  window.addEventListener("resize", this.myEventHandler);
3},
4destroyed() {
5  window.removeEventListener("resize", this.myEventHandler);
6},
7methods: {
8  myEventHandler(e) {
9    // your code for handling resize...
10  }
11}