Skip to content

Format Links in the Documentation Markdown from SourceKit #416

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 2 commits into from
Jul 15, 2021
Merged

Format Links in the Documentation Markdown from SourceKit #416

merged 2 commits into from
Jul 15, 2021

Conversation

LebJe
Copy link
Contributor

@LebJe LebJe commented Jul 14, 2021

This pull request adds formatting for links in the markdown documentation from SourceKit.

Before:

Before

After:

After

@LebJe LebJe requested a review from benlangmuir as a code owner July 14, 2021 20:27
@benlangmuir
Copy link
Contributor

Would you mind adding a test case for this? Something like this in testXMLToMarkdownDeclaration in "LocalSwiftTests.swift" (I didn't actually run this):

XCTAssertEqual(try! xmlDocumentationToMarkdown("""
      <Link href="https://example.com">My Link</Link>
      <Link>My Invalid Link</Link>
      """), """
      [My Link](https://example.com)
      My Invalid Link  
      """)

@benlangmuir
Copy link
Contributor

@swift-ci please test

@benlangmuir
Copy link
Contributor

swiftlang/swift-driver#757

@swift-ci please test

@CodaFi
Copy link
Contributor

CodaFi commented Jul 14, 2021

@swift-ci please test

@CodaFi CodaFi closed this Jul 14, 2021
@CodaFi CodaFi reopened this Jul 14, 2021
@benlangmuir
Copy link
Contributor

@swift-ci please test

@benlangmuir benlangmuir merged commit 0aad9a9 into swiftlang:main Jul 15, 2021
@LebJe LebJe deleted the formatLinks branch July 15, 2021 17:12
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.

3 participants