You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository was archived by the owner on Apr 25, 2018. It is now read-only.
You could define a component in a separate file sort of like this:
define person with name, email, photo
section.person
h1
given email
a(href mailto:#{email}) #{name}
unless email
span #{name}
img(src #{photo})
And then you can use it like this:
each users as user
person(
name #{user.name}
email #{user.email}
photo #{user.photo_url}
)
We should probably make a gem or something to handle importing these.
Thoughts on syntax, etc? How do we differentiate between passing regular string attributes versus passing template hashes? (do we even want to support template hash parameters?)
You could define a component in a separate file sort of like this:
And then you can use it like this:
We should probably make a gem or something to handle importing these.
Thoughts on syntax, etc? How do we differentiate between passing regular string attributes versus passing template hashes? (do we even want to support template hash parameters?)