I want to add a team members section in my theme, I want to have one file that would contain multiple entries of members and add it to the template, Is there a way to do this by using a .yaml
file or is there any other way?
You could just create a user/config/members.yaml
file and in that have an array of members.
kaladan:
name: kaladan
email: kaladan@mail
image: kaladan.png
bio: simple bio
joeblow:
name: Joe Blow
email: joe@blow.com
image: joe.jpg
bio: joe bio
Then you can use this in your template via:
{% for member in config.members %}
Name: {{ member.name }}
Email: {{ member.email }}
{% endfor %}
---
Thank you. This will make my work a lot easier.