simple-web-server icon indicating copy to clipboard operation
simple-web-server copied to clipboard

spa custom regex expression

Open ethanaobrien opened this issue 2 years ago • 7 comments

I made a spa app and I now finally realize why you would want to have a custom regex expression.

The current one is /.*\.[\d\w]+$/ which basically means if the file (it basically pops after the last /) has a . (dot) and then something after the dot then the spa page will not (since we want it to be null) be rendered. A custom regex would allow the user to only render the spa html with something like a certain extension or a specific folder in the path or something like this.

Going back to this (I couldnt find the exact location but I remember the conversation)

spa does NOT just render the page when no file is found, it renders the page when the regex expression is not met.

Let me know what you think

ethanaobrien avatar Apr 28 '22 17:04 ethanaobrien

I understand how the custom regex feature works, as you've described. The reason I think we shouldn't add it is because it doesn't feel "simple". Very few users will need this feature. And those who do may already need more than it can offer, such as wanting to set up multiple different rewrites. This seems like the kind of thing that could instead be a per-directory htaccess-like option.

terreng avatar May 11 '22 22:05 terreng

That is probably true. Do you want me to add it to the htaccess file? this is kind of already implemented (with the htaccess request versioning feature) or should we just leave it?

ethanaobrien avatar May 11 '22 22:05 ethanaobrien

Let's leave it for now, and revisit it later.

terreng avatar May 11 '22 23:05 terreng

online wan features update

hardduty avatar Jan 27 '23 05:01 hardduty

wan port sharing if port open router then internal lan ip or external lan ip convert method please demonstration one youtube video local level access okay wan level level access many problems

hardduty avatar Jan 27 '23 05:01 hardduty

@hardduty I don't understand what you're saying. Could you please open a new issue on GitHub? Could you please communicate more clearly?

terreng avatar Jan 27 '23 15:01 terreng

I think he is asking how to make the website available on the internet and that he's having problems accessing it from another device on the same lan network.

ethanaobrien avatar Jan 27 '23 15:01 ethanaobrien