Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Filter modifier for Antlers #1222

Open
stephenmeehanuk opened this issue Sep 6, 2024 · 0 comments
Open

Filter modifier for Antlers #1222

stephenmeehanuk opened this issue Sep 6, 2024 · 0 comments

Comments

@stephenmeehanuk
Copy link

stephenmeehanuk commented Sep 6, 2024

Can we have a filter modifier?

I had this data from a testimonial block

 bq_cite:
          bq_name: null
          bq_position: 'Important Role'
          bq_company: 'Company Name'

Using this

{{ bq_cite | join(', ') }}

Output this, notice the comma at the start.

, Important Role, Company Name

I posted this in Discord, and a very helpful member helped me out with this:

{{$ collect($bq_cite)->filter()->join(',') $}}

Which works!

Is it possible to create an Antlers filter modifier?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant