title: pass parameter in URL using vuejs and laravel
body: <p>I wanna display data with specefic ID in laravel using vuejs.
  I get the ID from the link but it seems that there is no request sent to the controller.
  <strong>api.php :</strong></p>
  
  <pre><code>    &lt;?php
  
  use Illuminate\Http\Request;
  
  
  Route::middleware('auth:api')-&gt;get('/user', function (Request $request) {
      return $request-&gt;user();
  });
  
  Route::resource('user','API\UserController');
  Route::resource('departement','API\DepartementController');
  Route::resource('specialite','API\SpecialiteController')-&gt;parameters(['specialite'=&gt;'id']);
  </code></pre>
  
  <p><strong>my controller :</strong></p>
  
  <pre><code>public function show($id)
      {
          $specialite=Specialite::with('dep')-&gt;findOrFail($id);
          $spec = Specialite::with('dep')-&gt;where('id',$specialite)-&gt;get();
          return $spec;
      }
  </code></pre>
  
  <p><strong>my view :</strong></p>
  
  <pre><code>&lt;script&gt;
      export default {
  
          data(){
          return{
          specialites:{},
          form: new Form({
              id:'',
              name:'',
              user_id:'',
              bio:''
          }),
          id:0,
          }
  
          },
  
      methods: {
          loadspecialite(){
          //axios.get('api/user').then(({data})=&gt;(this.enseignants=data.data));
          axios.get('api/specialite/'+this.id).then(response=&gt;{this.specialites=response.data;});
      },
          created() {
              this.id=this.$route.params.id;
              this.loadspecialite();
              Fire.$on('AfterCreate',()=&gt;{
              this.loadspecialite();
  
              })
  
          }
      }
  &lt;/script&gt;
  </code></pre>
  
  <p><strong>Vue-router:</strong></p>
  
  <pre><code> let routes = [
    { path: '/Profile/:id', component: require('./components/a.vue').default },
  ]
  </code></pre>
  
  <p>thank you.
  hope tou will help me.</p>