osiemsiedem / laravel-autolink
A Laravel package for converting URLs in a given string of text into clickable links.
Installs: 81 654
Dependents: 0
Suggesters: 0
Security: 0
Stars: 13
Watchers: 3
Forks: 4
Open Issues: 0
Requires
- php: ^8.2
- illuminate/support: ^11.0
- spatie/laravel-html: ^3.6
- symfony/polyfill-mbstring: ^1.29
Requires (Dev)
- mockery/mockery: ^1.6
- phpunit/phpunit: ^10.5
README
A Laravel package for converting URLs in a given string of text into clickable links.
Requirements
- PHP >= 8.2
- Laravel >= 11.0
Installation
composer require osiemsiedem/laravel-autolink
Usage
use OsiemSiedem\Autolink\Facades\Autolink; echo Autolink::convert('Check this out - www.example.com. This will be ignored - <a href="http://example.com">My awesome website</a>.'); // Check this out - <a href="http://www.example.com">example.com</a>. This will be ignored - <a href="http://example.com">My awesome website</a>.
Testing
./vendor/bin/phpunit
Credits
This package is based on the Rinku library.
License
Please see the LICENSE.md file.