Skip to content

Conversation

@marinaaisa
Copy link
Member

Explanation: We want to normalize Sample Code URLs, by adding the baseUrl to them if the path is relative and the baseUrl is provided. If the path is absolute or the baseUrl is not provided, it does not prefixes the URL.

Scope: Sample Code
Issue: rdar://165347857.
Risk: Low
Testing: added new unit test.
Reviewer: @mportiz08
Original PR: #979

We want to normalize Sample Code URLs, by adding the baseUrl to them if
the path is relative and the baseUrl is provided. If the path is
absolute or the baseUrl is not provided, it does not prefixes the URL.

Because the component CallToActionButton.vue is not only being used for
Sample Code links, we created a new prop called linksToAsset that will
normalize the relative URLs, in the cases that they are assets, like
Sample Code.
@marinaaisa marinaaisa changed the base branch from main to release/6.3 December 10, 2025 13:52
@marinaaisa
Copy link
Member Author

@swift-ci test

@marinaaisa marinaaisa merged commit ddbf320 into swiftlang:release/6.3 Dec 10, 2025
1 check passed
@marinaaisa marinaaisa deleted the 6.3/normalize-sample-code-url branch December 10, 2025 13:58
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants