Symfony 4, include assets from vendor directory : <p>I would like to load vendor assets, downloaded with composer inside vendor directory, from my twig template.</p>

<p>Using a relative path is one solution (in this example I'm going to include bootstrap css, but the same problem is for any other libs required from composer, as jQuery, jQueryUI  etc. )</p>

<pre><code>&lt;link rel="stylesheet" href="{{ asset('../vendor/twbs/bootstrap/dist/css/bootstrap.min.css') }}" &gt;
</code></pre>

<p>Symfony docs suggest to use asset:install in order to generate a symlink from vendor directory to public, but I was unable to understand how it works.
assets:install -h wasn't so clear to let me understand how to link a specific vendor path to the public directory.</p>

<p>Creating a simlink with </p>

<pre><code>ln -s /path/of/vendor/lib /path/public/dir
</code></pre>

<p>works fine but, symlinks created will be deleted every time I look for an update with composer.</p>

<p>Any idea about "a best practice" to include assets from vendor directory?</p>

<p>Thank you</p>
