This change refactors out the plugin code from converse-core into
src/converse-puggable.js
Additionally, plugins now have an optional attribute `optional_dependencies`
which is an array of dependencies which are "nice-to-have" but not essential.
Work has also been done to ensure that a plugins' dependencies are first loaded
before the plugin itself.
Remove interval handler and the user activity handler.
Make sure the connection is reset when logging out.
Also removed the reconnectTimeout, instead debounce the reconnect method by 1 second.
According to the require.js documentation, if you are using "require" in HTML,
then the data-main attribute should not be used.
http://www.requirejs.org/docs/api.html#data-main
So merged main.js into converse.js, which appears to solve the problem.