Skip to content

Merge two Url with + operator #36

@o-nnerb

Description

@o-nnerb

I would like to add two URL to create a new one, for example:

Url("https://example.com/api/v1") + Url("/settings")

But, I believe that we can add one Url with a string too like that:

func + (_ url: Url, _ complementary: String) -> Url { Url("\(url.value ?? "")\(complementary)") }

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or request

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions