Open HarryBurns opened 8 years ago
That would be a change in RFG itself, not in the Gul plugin.
This makes sense, as an empty string would explicitly means "no path at all". But this change might have implication in other parts so I need to investigate this seriously.
I'm curious: why would you want to remove the slash?
It is all about relative path stuff. If my index.html
located in http://localhost/foobar/
This link
<link rel="shortcut icon" href="/favicon.ico?ver=95763">
will lead to
Failed to load resource: the server responded with a status of 404 (Not Found) http://localhost/favicon.ico?ver=95763
@HarryBurns Have you considered using the files_location
property? e.g.
"files_location": {
"type": "path",
"path": "/foobar/"
}
See the API docs for more details.
@haydenbleasel No, it will not work this way. http://localhost/foobar/
is just a virtual folder on server of my webapp. I don't know were my webapp will be deployed, so I can't rely on it during build process.
Same situation for our team. We would like this as well. We don't know that when deployed, the path will always be /foobar or whatever. For now, we have it generating everything with iconsPath: 'assets/images'
because that will get us the right values in index.html knowing that not being in the root is not ideal.
For now, it seems that using iconsPath: './'
will produce links in index.html that work in this situation.
Hello there!
Is it possible to remove leading slash in URLs when
iconsPath
parameter is set to empty string?