Skip to content

Commit

Permalink
Merge pull request #1101 from phpDocumentor/fix/auto-detect-inline-links
Browse files Browse the repository at this point in the history
[BUGFIX] add support for auto detected inline links
  • Loading branch information
jaapio authored Oct 1, 2024
2 parents 77a7313 + 524d12e commit 8e7f4e3
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,7 @@
namespace phpDocumentor\Guides\Markdown;

use League\CommonMark\Environment\Environment as CommonMarkEnvironment;
use League\CommonMark\Extension\Autolink\AutolinkExtension;
use League\CommonMark\Extension\CommonMark\CommonMarkCoreExtension;
use League\CommonMark\Node\Block\Document;
use League\CommonMark\Node\NodeWalker;
Expand Down Expand Up @@ -45,6 +46,7 @@ public function __construct(
) {
$cmEnvironment = new CommonMarkEnvironment(['html_input' => 'strip']);
$cmEnvironment->addExtension(new CommonMarkCoreExtension());
$cmEnvironment->addExtension(new AutolinkExtension());
$this->markdownParser = new MarkdownParser($cmEnvironment);
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ <h1>Sample Markdown Document</h1>
<p>See <a href="https://www.example.com">https://www.example.com</a> for additional information.</p>


<p>See also <a href="https://www.example.com/more">https://www.example.com/more</a>.</p>
<p>See also <a href="https://www.example.com/more">https://www.example.com/more</a>.</p>

</div>
<!-- content end -->

This file was deleted.

0 comments on commit 8e7f4e3

Please sign in to comment.