Moved call to initialize to HTML markup

- This is more user-friendly and we want it to be outside of the files bundled
  and minimized by require.js
This commit is contained in:
JC Brand 2013-07-24 23:58:04 +02:00
parent 9a0531120d
commit 9e05ed8d76
2 changed files with 15 additions and 14 deletions

View File

@ -164,4 +164,18 @@
</script>
<script type="text/javascript">try { var pageTracker = _gat._getTracker("UA-2128260-8"); pageTracker._trackPageview(); } catch(err) {}</script>
</body>
<script>
require(["jquery", "converse"], function ($, converse) {
converse.initialize({
auto_list_rooms: false,
auto_subscribe: false,
bosh_service_url: 'https://bind.opkode.im', // Please use this connection manager only for testing purposes
hide_muc_server: false,
i18n: locales.en, // Refer to ./locale/locales.js to see which locales are supported
prebind: false,
show_controlbox_by_default: true,
xhr_user_search: false
});
});
</script>
</html>

15
main.js
View File

@ -1,14 +1 @@
require(["jquery", "converse"], function($, converse) {
// Most of these initialization values are the defaults but they're
// included here as a reference.
converse.initialize({
auto_list_rooms: false,
auto_subscribe: false,
bosh_service_url: 'https://bind.opkode.im', // Please use this connection manager only for testing purposes
hide_muc_server: false,
i18n: locales.en, // Refer to ./locale/locales.js to see which locales are supported
prebind: false,
show_controlbox_by_default: true,
xhr_user_search: false
});
});
require(["jquery", "converse"], function($, converse) {});