title: Nuxt JS reload data by url parameter
body: <p>I have a webpage with a fixed Header. There I have the items &quot;Main Accounts&quot; and &quot;Sub Accounts&quot;. The pages are completly the same and have the same functionality except that they call different routes of the API to fetch different data. I dont want two different files for that. Everything should be one file and I just read a variable and change the url depends on that.
  My header has some nav-items:</p>
  <pre><code>&lt;b-nav-item to=&quot;/accounts&quot;&gt;Main&lt;/b-nav-item&gt;
  &lt;b-nav-item to=&quot;/accounts&quot;&gt;Subs&lt;/b-nav-item&gt;
  </code></pre>
  <p>Now I need to pass a variable to that redirection, that I can read in the accounts page and then change the link for getting datas.
  I tried so far:</p>
  <pre><code>&lt;b-nav-item to=&quot;/accounts?main=true&quot;&gt;Main&lt;/b-nav-item&gt;
  &lt;b-nav-item to=&quot;/accounts?main=false&quot;&gt;Subs&lt;/b-nav-item&gt;
  </code></pre>
  <p>I can read the parameter in that url with this.$route.query.main, but my problem is, the page doesnt reload, if I switch between the 2 pages. The url is changing, but I dont know how to react to that change.
  I tried it with a click event and force reload:</p>
  <pre><code>@click=&quot;$router.go({path:'/accounts', force:true})
  </code></pre>
  <p>but that forces to reload the complete page.</p>
  <p>My favourite solution would be to create a folder structure or whatever. Then have two routes:
  /mainaccounts and /subaccounts but both lead to the same file and in that file I read that the parameter and then decide what route I have to call depending on the link</p>