Add fallback to index.html
See original GitHub issuePlease add fallback to index.html for every “not real” file, pretty much the same way as connect-history-api-fallback
does (https://github.com/bripkens/connect-history-api-fallback#introduction):
- The request is a GET request
- which accepts text/html,
- is not a direct file request, i.e. the requested path does not contain a . (DOT) character and
- does not match provided pattern
Not sure if I am not creating a duplicate, but I haven’t found one… I only found a fork: https://github.com/riceboyler/http-server.
Issue Analytics
- State:
- Created 7 years ago
- Reactions:23
- Comments:18 (3 by maintainers)
Top Results From Across the Web
node http-server to respond with index.html to any request
This implementation will always respond with index.html if the requested file is not found, and it's almost as simple as using http-server , ......
Read more >How to Setup Web Hosting Fallback to index.html - General
I'm hosting a Single Page App from a subdirectory of root/web. I need to redirect all calls to urls in that directory to...
Read more >Web app routing with fallback | Better world by better software
the web application in index.html initializes itself, looks at location and routes to /about view. Not only this is a much better experience...
Read more >mod_dir - Apache HTTP Server Version 2.4
A file written by the user, typically called index.html . The DirectoryIndex directive sets the name of this file. This is controlled by...
Read more >connect-history-api-fallback v2.0.0
This tiny middleware addresses some of the issues. Specifically, it will change the requested location to the index you specify (default being /index.html...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
However I wonder why this option is not in this current project.
For people who need it:
Note that
spa-http-server
replaceshttp-server
bin.