Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- {% for d in data %}
- {% set text = d.resumen |split(' ') %}
- {% set t2 = '' %}
- {% if text|length > 10 %}
- {% for t in text|slice(0, 10) %}
- {% set t2 = t2 ~ ' ' ~ t %}
- {% endfor %}
- {% set t2 = t2 ~ '...' %}
- {% else %}
- {% set t2 = text|join(' ') %}
- {% endif %}
Add Comment
Please, Sign In to add comment