question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Use urlRewrite technique to redirect index.html to support html5 mode

See original GitHub issue

When html5 mode is on, refresh causes the web server to seek for the given folder, To support this right we need a feature to always perform url rewrite to index.html (or some other page) automatically.

Something like:

-u foo.html where default of -u is index.html

Thanks

Issue Analytics

  • State:closed
  • Created 9 years ago
  • Reactions:1
  • Comments:6

github_iconTop GitHub Comments

3reactions
jakubknejzlikcommented, Mar 2, 2015

http-server is heavily dependent on ecstatic module and imo this is the right place to add this functionality in first place (then add support for this in http-server). Right now my current solution is duplicate the index.html and name it 404.html…isn’t the best, but works.

0reactions
indexzerocommented, Mar 19, 2015

Closing as a duplicate of #80.

Read more comments on GitHub >

github_iconTop Results From Across the Web

Use urlRewrite technique to redirect index.html to support html5 ...
When html5 mode is on, refresh causes the web server to seek for the given folder, To support this right we need a...
Read more >
How do I configure IIS for URL Rewriting an ... - Stack Overflow
I write out a rule in web.config after $locationProvider.html5Mode(true) is set in app.js . Hope, helps someone out. <system.webServer> <rewrite> <rules> ...
Read more >
Redirecting and Remapping with mod_rewrite
Solution: You can use mod_rewrite to redirect these URLs to the new server, but you might also consider using the Redirect or RedirectMatch...
Read more >
Creating Rewrite Rules for the URL Rewrite Module
We will create a rewrite rule by using URL Rewrite UI in IIS Manager. To do this, follow these steps: Go to IIS...
Read more >
How To Redirect to Another Webpage - W3Schools
Learn how to redirect to another webpage using JavaScript. Redirect a Webpage. There are a couple of ways to redirect to another webpage...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found