get params from route vuejs

JavaScript
const User = {
  template: '<div>User {{ $route.params.id }}</div>'
}

Source

Also in JavaScript: