Rendering Images on Cards
It’s been said that a picture is worth a thousand words. It wouldn’t be a great idea to have a card with a thousand words in it, but adding an image to a card could carry just as much value.
For example, suppose that we want to return a card in response to scheduling a trip. The card could include text describing the planned trip and be informative. But including an image of the destination along with that information will provide an enormous amount of visual value to the card.
We’ll start by adding new language-specific strings for the new card’s title and content to languageStrings.js:
| module.exports = { |
| en: { |
| translation: { |
| ... |
| SCHEDULED_CARD_TITLE: 'Enjoy your ... |
Get Build Talking Apps for Alexa now with the O’Reilly learning platform.
O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.