Answers for "check if alpine js is activated in website"

0

check if alpine js is activated in website

You can check by adding below code and if h1 toggled on click then setup was 
done successfully! 
  
<div x-data="{ isOpen: true }">
   <button x-on:click=" isOpen = !isOpen">Toggle</button>
	<h1 x-show="isOpen">Alpinjs</h1>
</div>
Posted by: Guest on May-20-2021

Code answers related to "Javascript"

Browse Popular Code Answers by Language