Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR JAVASCRIPT

using the watch method to monitor route updates in vue

watch: {
  movie(movie) {
    // Fetch data about the movie
    fetch(`/${movie}`).then((data) => {
      this.movieData = data;
    });
  }
}
Source by michaelnthiessen.com #
 
PREVIOUS NEXT
Tagged: #watch #method #monitor #route #updates #vue
ADD COMMENT
Topic
Name
4+5 =