Created
March 2, 2024 22:28
-
-
Save atakde/86e5c41366cdc6e8283792fe0f77d3b9 to your computer and use it in GitHub Desktop.
Termwind php example
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
require 'vendor/autoload.php'; | |
use function Termwind\{render}; | |
use function Termwind\{ask}; | |
$answer = ask(<<<HTML | |
<span class="mt-1 ml-2 mr-1 bg-green px-1 text-black"> | |
What is your name? | |
</span> | |
HTML); | |
render(<<<HTML | |
<span class="mt-1 ml-2 mr-1 bg-green px-1 text-black"> | |
Hello, $answer! | |
</span> | |
HTML); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment