Hey folks,
here we are again!!
I’ve insert this code to create “read more” and “read less” button on all my category pages but, I don’t know why my text become duplicate.
Please can you check my code and let me know where I wrong?
Thank you so much!!
{% assign collection_strip = collection.description | strip %}
{% if collection_strip != "" %}
{% assign paragraphs = collection.description | newline_to_br | split: '
'%}
{{paragraphs}}
{% assign len = paragraphs | size %} {{paragraphs | slice: 2, len}}
{% endif %}