filter the tpe using stimulus

hi guys maybe some of you here have experience this and some of you might say this is easy for you, but can you please help me how to create a stimulus code to filter a specific type when i click one of this button <div class="job-button"> <a class="job-headline" data-action="click->jobs#vollzeit" data-type="Vollzeit">vollzeit</a> <a class="job-headline" data-action="click->jobs#filterJobsFromButton" data-type="Teilzeit">teilzeit</a> <a class="job-headline" data-action="click->jobs#filterJobsFromButton" data-type="Praktikum">praktikum</a> </div>. here is my code <div class="jobs-grid" data-target="jobs.jobsGrid"> {% for blocks in block.jobs %} <div class="job-item" data-target="jobs.jobItem" data-job-type="{{ blocks.type }}"> <div class="job-row"> <div class="job-type">{{ blocks.type }}</div> <div class="job-wrapper"> <span class="job-title">{{ blocks.title }}</span> <span class="job-text">{{ blocks.ctaTitle }}</span> </div> </div> </div> {% endfor %} what i want here is when i clicked the first button it will obly show up for example the "vollzeit"
No description
0 Replies
No replies yetBe the first to reply to this messageJoin
Want results from more Discord servers?
Add your server