You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
What I mean by a "dirty" path is simply a path that has trailing and leading slashes, without accounting for what other URL parts are following or leading.
Current behavior
If we try to merge parts of a URL that contains leading and trailing slashes, building a relative path out of these data would lead to an incorrect path.
In JavaScript, there is a module path that has a join function that act in a similar fashion, but will merge the parts of a path and make a valid url at the end (it also uses the operating system's default path separator but this is irrelevant here).
There could be a new Url.Builder.join function to prevent any breaking change in the current API instead.
Context
What I mean by a "dirty" path is simply a path that has trailing and leading slashes, without accounting for what other URL parts are following or leading.
Current behavior
If we try to merge parts of a URL that contains leading and trailing slashes, building a relative path out of these data would lead to an incorrect path.
Expected behavior
It would be nice if the function somehow cleaned the URLs. The end result (with the above data) could look like that.
Additional Context
In JavaScript, there is a module
path
that has ajoin
function that act in a similar fashion, but will merge the parts of a path and make a valid url at the end (it also uses the operating system's default path separator but this is irrelevant here).There could be a new
Url.Builder.join
function to prevent any breaking change in the current API instead.Like
The text was updated successfully, but these errors were encountered: