angular prod apache config for route

Solutions on MaxInterview for angular prod apache config for route by the best coders in the world

showing results for - "angular prod apache config for route"
Miguel
08 Nov 2017
1Option 2: .htaccess
2
3<IfModule mod_rewrite.c>
4    RewriteEngine on
5
6    # Don't rewrite files or directories
7    RewriteCond %{REQUEST_FILENAME} -f [OR]
8    RewriteCond %{REQUEST_FILENAME} -d
9    RewriteRule ^ - [L]
10
11    # Rewrite everything else to index.html
12    # to allow html5 state links
13    RewriteRule ^ index.html [L]
14</IfModule>
Emelie
27 Jan 2017
1Option 1: Virtual Host
2
3<VirtualHost *:80>
4    ServerName my-app
5
6    DocumentRoot /path/to/app
7
8    <Directory /path/to/app>
9        RewriteEngine on
10
11        # Don't rewrite files or directories
12        RewriteCond %{REQUEST_FILENAME} -f [OR]
13        RewriteCond %{REQUEST_FILENAME} -d
14        RewriteRule ^ - [L]
15
16        # Rewrite everything else to index.html
17        # to allow html5 state links
18        RewriteRule ^ index.html [L]
19    </Directory>
20</VirtualHost>