wiki-v1
wiki-v1 copied to clipboard
Why wiki.js changes underscores to dashes when files are uploaded?
Actual behavior
I upload a_b.png
- get a-b.png
.
Expected behavior
Expected to have a_b.png
in my file list.
Also, other name mangling happens - s24
becomes s-24
. Since I'm uploading lab project files to wiki, I need to keep names clean, and I use combination of various numbers, underscores, and dashes - changing underscores to dashes really screws everything up.
Because Wiki.js relies on kebab-case filenames to read and write data.
I'll think of a solution for 2.0 to get around this limitation.
Yes, that I understood. But was there any reason for that kebab-case? Manually uploading the files and setting proper names in the links works without any problems.
Non-technical users are really bad at using proper file naming. They include spaces, accents and other non url friendly characters, which is why all filenames go through a kebab-case conversion first.
Okay, I can understand that non-url-friendly characters are bad, but adding dashes between letters and numbers and replacing underscores seems a little too much.
Also, why force url-friendliness at all? There will always be non-latin languages, which are completely url-unfriendly (all or almost all characters are encoded). Maybe it is easier to just leave all the names as-is?
Any traction on this? This makes building any cohesion between folder structure and updates very difficult. As an example, I use this to track my cloud tenants, and there's a 4 character identifier that is unique to the tenant. My folder structure is broken down by that ID, which is great. But managing them in GIT is a pain because of all the oddly placed " - " between the 4 characters