port(_:)
Modifies a format style to display a URL’s port component in accordance with the provided option.
Declaration
func port(_ strategy: URL.FormatStyle.ComponentDisplayOption = .omitIfHTTPFamily) -> URL.FormatStyleParameters
- strategy:
A component display option that indicates when, if ever, to display the port component.
Return Value
A modified URL.FormatStyle that incorporates the specified behavior.