Return an object on Talk.render to control the embed

This commit is contained in:
Chi Vinh Le
2017-07-29 00:17:23 +07:00
parent 7f38c70e58
commit 85e478cf3f
5 changed files with 61 additions and 16 deletions
+1 -1
View File
@@ -26,7 +26,7 @@
<p><a href="admin">Admin</a> - <a href="assets">All Assets</a></p>
<div id='coralStreamEmbed'></div>
<script src="embed.js" async onload="
Coral.Talk.render(document.getElementById('coralStreamEmbed'), {
window.TalkEmbed = Coral.Talk.render(document.getElementById('coralStreamEmbed'), {
talk: '<%= BASE_URL %>',
asset_url: '<%= asset_url ? asset_url : '' %>',
asset_id: '<%= asset_id ? asset_id : '' %>',