Closed muuvmuuv closed 10 months ago
Hey thanks for the issue Marvin. Is there a specific issue with spaces and parentheses on a particular OS? Wouldn't proper quoting address these? If starting from scratch this seems sensible, but I'm loathe to release an update that breaks existing paths without a clear need.
I haven't had a problem with this currently but had one a long time ago with paths on Mac and Windows with spaces, because sometimes on Mac you need to do path\ with\ space/to-some-where
to tell MacOS that these are spaces and it would look more generic to me.
Of course this would be a breaking change. It's up to you.
Starting with vite.js 2.5.1 the font files of inter-ui are not found anymore. Although I think this is a problem inside vite, I think it would also be fixed with simpler file and path names avoiding special chars like (
or )
and spaces.
BTW: Thanks for making inter font available so smoothly!
Hey holtwick, thanks for getting in touch. Do you have a sense of how this could be mitigated in vite? E.g. is it due to how webpack handles paths, and can escaping be used to preserve the folder original names?
I'd be happy to add items to the docs about mitigation, or to switch the CSS to use escaped path strings if they work seamlessly. Given that many people use this repo and hardcode the file paths I'm pretty loathe to change the folder names.
If there isn't a great mitigation, I guess I could add a duplicate set of folders/files that use safe paths. It's not particularly elegant, but npm modules aren't exactly free of bloat anyway.
Hi @philipbelesky I added also a ticket on their side and hope they will fix it with the next release: https://github.com/vitejs/vite/issues/4774 Yet I didn't find a way to mitigate (besides using vite <= 2.5.0 ;) ), but will get back as soon as I find one.
It seems that the issue with vite https://github.com/vitejs/vite/issues/4774 has been solved in vite 2.5.2. So just avoiding to use 2.5.1 bypasses the issue. ;)
Good to hear! I'll keep this open as it seems like a relatively broad issue. If others are having the same issue, let me know and I'll consider the duplicated-folders option.
I'm trying to use this repo on Windows. And the folder names are causing issues when trying to copy them to my dist
folder.
I have not found a way to target the space and parentheses in the folder name with npm scripts.
Using the cpy-cli
package, the following script works:
"copy:fonts-inter": "cpy \"node_modules/inter-ui/**/Inter-{italic,roman}.var.woff2\" \"dist/assets/vendor/inter-ui/inter/\""
But, I cannot I can target the individual Inter (web)
folder. I'm not sure if this a Windows + glob syntax thing. But, using all lowercase letters separated by hyphens would fix it.
Hey, sorry to hear the folder paths are causing issues. Inter is beta testing a major version bump and when that is released I’ll look at improving the folder paths; either as a breaking change or as duplicates of the existing structure.
Proposed folder names:
variable
variable-latin
web
web-latin
web-hinted
web-hinted-latin
Proposed filenames: as per the main Inter release. So Inter-Bold.woff2
would exist in all of the web
and web-*
folders
IMO it is better to have readable names for folders that should be accessible through tools like Webpack. There could be problems with different operating systems and the space and uppercase letter.
Inter (web hinted) -> inter-hinted Inter (web) -> inter