awcodes / html-faker
A better html faker.
Installs: 1 459
Dependents: 3
Suggesters: 0
Security: 0
Stars: 13
Watchers: 2
Forks: 2
Open Issues: 0
Requires
- php: ^8.1
- illuminate/contracts: ^10.0|^11.0
- spatie/laravel-package-tools: ^1.14.0
Requires (Dev)
- larastan/larastan: ^2.9.2
- laravel/pint: ^1.0
- nunomaduro/collision: ^7.8|^8.1
- orchestra/testbench: ^8.0|^9.0
- pestphp/pest: ^2.0
- pestphp/pest-plugin-arch: ^2.0
- pestphp/pest-plugin-laravel: ^2.0
- phpstan/extension-installer: ^1.1
- phpstan/phpstan-deprecation-rules: ^1.0
- phpstan/phpstan-phpunit: ^1.0
- spatie/laravel-ray: ^1.26
README
Installation
You can install the package via composer:
composer require awcodes/html-faker
Usage
use Awcodes\HtmlFaker\HtmlFaker; HtmlFaker::make() ->heading(int | string | null $level = 2) ->paragraphs(int $count = 1, bool $withRandomLinks = false) ->unorderedList(int $count = 1) ->orderedList(int $count = 1) ->image(int $width = 640, int $height = 480, string $text = null) ->link(string $text = null, string $url = null) ->video(?string $provider = 'youtube', ?int $width = 640, ?int $height = 480) ->details() ->code(string | null $className = 'hljs') ->blockquote() ->hr() ->br() ->table() ->generate(); // <-- this is required to generate the html
Testing
composer test
Changelog
Please see CHANGELOG for more information on what has changed recently.
Contributing
Please see CONTRIBUTING for details.
Security Vulnerabilities
Please review our security policy on how to report security vulnerabilities.
Credits
License
The MIT License (MIT). Please see License File for more information.