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.

Help users who accidentally include file extensions in urls

See original GitHub issue

Today I was helping a user through some bugs in their prototype. One of the issues I observed is that they’d included file extensions in their urls and in their GET, POSTs, routes and renders.

Nominally the kit doesn’t need this, and I think it can lead to some unexpected behaviour. However for the most part things still appear to work.

If a user comes from a static html prototyping background there’s a good chance they might think they need extensions.

I wonder if there’s anything we could do to help with this?

Perhaps have the kit log a warning to the console when it gets a get request with an extension?

Issue Analytics

  • State:open
  • Created 2 years ago
  • Comments:7 (6 by maintainers)

github_iconTop GitHub Comments

1reaction
edwardhorsfordcommented, Feb 1, 2022

@trang-erskine This is an issue I used to see frequently when running Prototype Kit training with @joelanman - it’s a logical thing to do when you want to link to a file - and especially if users have prior experience with html there’s a good chance they might do this.

0reactions
joelanmancommented, Feb 2, 2022

theoretically that should just redirect to the same path without .html and still work, but worth reviewing

Read more comments on GitHub >

github_iconTop Results From Across the Web

Google's John Mueller Says File Extensions in URLs Do Not ...
“Will removing .html from my URLs help my site?” The short answer is: no. Mueller says Google doesn't care whether URLs end in...
Read more >
33: How to Remove the Page File Extension From the URL
How to Remove the Page File Extension From the URL | Learn HTML & CSS | HTML Tutorial | mmtuts. In this HTML...
Read more >
Serving URLs with File Extensions in an ASP.NET MVC ...
I ran into an issue trying to create a specific file URL for Windows Live Writer ... file based URL with an extension...
Read more >
Identify and interrupt downloads of potentially dangerous files
Understand how Microsoft Edge identifies and interrupts downloads of potentially dangerous files.
Read more >
How come some site urls do not include a file extension?
File extensions are not used because of the idea that URIs (and therefore URLs) should be independent of implementation - if you want...
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