First off, thanks for amazing framework! I've used Botkit and Microsoft Bot Framework before, Botpress is much better :+1:
However, I can't send hashtags in the messages.
content.yml:
news:
- on: facebook
template_type: generic
elements:
- title: {{{title}}}
default_action:
type: web_url
url: {{{url}}}
webview_height_ratio: compact
webview_share_button: hide
buttons:
- type: postback
title: Process
payload: PROCESS
- type: postback
title: Skip
payload: SKIP
index.js:
event.reply('#news', {
title: 'Saxo Bank Offers Bitcoin Exchange Traded Notes #Bitcoin',
url: 'https://twitter.com/BTCTN/status/902225054523674626'
})
The "#Bitcoin" part gets chopped off. It happens because it's treated as comment by YAML parser, which runs after Mustache promptly replaces {{{title}}} with actual title.
Suggested fix:
Thanks Denis, totally agree with the fix! We should also actually only replace the mustache for the bloc currently in use (which is not the case atm).
In the mean time, you could use "{{{title}}}" (i.e. double quotes)
A PR would be awesome :)
@slvnperron thanks for suggesting double quotes - it worked!
Can't work on a PR right now due to a deadline, but will keep it in mind for future)
I want to know your opinions. But for me, this is not a problem at all and issue can be closed, it's a characteristic of yaml and it's well documented.
Sure thing, agreed.
Most helpful comment
Thanks Denis, totally agree with the fix! We should also actually only replace the mustache for the bloc currently in use (which is not the case atm).
In the mean time, you could use
"{{{title}}}"(i.e. double quotes)A PR would be awesome :)