So I've linked Firebase to my Vue project and now I want to display a portion of the content of a blog. I know that to display the entire blog content I can simple write the following within an html tag.
{{blogs[0].content}}
My question is, how do you display just a portion of it, for example the first 100 characters of the content? I've tried,
{{blogs[0].content[:100]}}
However that gives a compile error.
Also I have a second question, I have using bootstrap with Vue. More specifically the card cascade. Below shows a section of the bootstrap card cascade.
<b-card
title= blogs[0].title
img-src="https://placekitten.com/g/400/450"
img-alt="Image"
img-top
>
<b-card-text>
{{blogs[0].content[:10]}}
</b-card-text>
</b-card>
I want the title to be the title of blogs[0] but the way I have done it above just prints out "blogs[0].title"
:title="blogs[0].title", or usev-bind: