Options -Indexes

<IfModule mod_rewrite.c>
    RewriteEngine On

    RewriteRule ^(config|database|src|storage|templates|vendor)(/|$) - [F,L]
    RewriteRule ^(composer\.json|composer\.lock)$ - [F,L]

    RewriteCond %{REQUEST_FILENAME} !-f
    RewriteCond %{REQUEST_FILENAME} !-d
    RewriteCond %{DOCUMENT_ROOT}/public/$1 -f
    RewriteRule ^(.+)$ public/$1 [L]
</IfModule>
