title: Laravel nested route slug link
body: <p>I want to do route slug and im using slugable structure. I use SeoServiceProvider when define links.</p>
  
  <pre><code> foreach($categories as $category){
  
    $router-&gt;get($category['path'], 'App\Http\Controllers\User\CategoryController@index')
      -&gt;defaults('category', $category['id'])
      -&gt;name($category['path'])
      -&gt;middleware('web');
  };
  </code></pre>
  
  <p>this way the category structure works.</p>
  
  <pre><code>site.com/category
  site.com/category/subcategory
  site.com/category/subcategory/subsubcategory
  </code></pre>
  
  <p>I want to make the following structure </p>
  
  <pre><code>site.com/product
  site.com/category/product
  site.com/category/subcategory/product
  site.com/category/subcategory/subsubcategory/product
  </code></pre>
  
  <p>I need to do for this nested loop, Is there an easy way to do this.</p>