Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Unable to create paths with leading underscore #185

Open
vwong opened this issue Dec 27, 2024 · 1 comment
Open

Unable to create paths with leading underscore #185

vwong opened this issue Dec 27, 2024 · 1 comment

Comments

@vwong
Copy link
Contributor

vwong commented Dec 27, 2024

Version: 5.0.11

Details

In @marko/run, I want to be able to create routes with a leading underscore, like _foo. Using earlier versions, this was possible by URL encoding the path, eg %5ffoo+page.marko, avoiding the actual underscore itself, as that is a reserved character to create pathless directories.

It works ok with @marko/[email protected] + @marko/[email protected]
But breaks with @marko/[email protected] + @marko/[email protected], with all other packages remaining unchanged.

Windows don't like % in a filename, so I suspect we need another solution for this.

Your Environment

Mac OS 15.2
Node 22.11.0

@vwong
Copy link
Contributor Author

vwong commented Dec 27, 2024

Though I'm not directly affected, I suspect this use case is also affected https://discord.com/channels/725013179465203793/725013179926708226/1203402383426723882

One particular route looks something like: /5.x/generate/png. I'm struggling to get marko-run to recognize "5.x" as the route, and not /5/x. Any tricks to get this working?

Solution given by: https://discord.com/channels/725013179465203793/725013179926708226/1204509624791736320 is to URL Encode, which is where I ended up with %5f above.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant