Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
C
converse.js
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
nexedi
converse.js
Commits
97ccb6c4
Commit
97ccb6c4
authored
Sep 03, 2017
by
Weblate
Browse files
Options
Browse Files
Download
Plain Diff
Merge remote-tracking branch 'origin/master'
parents
c6c9bb3f
462a4890
Changes
14
Show whitespace changes
Inline
Side-by-side
Showing
14 changed files
with
202 additions
and
181 deletions
+202
-181
docs/source/builds.rst
docs/source/builds.rst
+1
-1
docs/source/configuration.rst
docs/source/configuration.rst
+5
-5
docs/source/developer_api.rst
docs/source/developer_api.rst
+3
-3
docs/source/developer_guidelines.rst
docs/source/developer_guidelines.rst
+2
-2
docs/source/features.rst
docs/source/features.rst
+3
-3
docs/source/index.rst
docs/source/index.rst
+1
-1
docs/source/plugin_development.rst
docs/source/plugin_development.rst
+174
-153
docs/source/quickstart.rst
docs/source/quickstart.rst
+3
-3
docs/source/security.rst
docs/source/security.rst
+1
-1
docs/source/style_guide.rst
docs/source/style_guide.rst
+3
-3
docs/source/theming.rst
docs/source/theming.rst
+1
-1
docs/source/translations.rst
docs/source/translations.rst
+2
-2
docs/source/troubleshooting.rst
docs/source/troubleshooting.rst
+2
-2
index.html
index.html
+1
-1
No files found.
docs/source/builds.rst
View file @
97ccb6c4
...
@@ -47,7 +47,7 @@ This command does the following:
...
@@ -47,7 +47,7 @@ This command does the following:
* Also, the CSS files in the ``./css`` directory will be minified.
* Also, the CSS files in the ``./css`` directory will be minified.
The Java
s
cript build files are contained in the ``./dist`` directory:
The Java
S
cript build files are contained in the ``./dist`` directory:
.. code-block:: bash
.. code-block:: bash
...
...
docs/source/configuration.rst
View file @
97ccb6c4
...
@@ -261,7 +261,7 @@ If ``authentication`` is set to ``anonymous``, then you will also need to provid
...
@@ -261,7 +261,7 @@ If ``authentication`` is set to ``anonymous``, then you will also need to provid
server's domain via the `jid`_ setting.
server's domain via the `jid`_ setting.
This is a useful setting if you'd like to create a custom login form in your
This is a useful setting if you'd like to create a custom login form in your
website. You'll need to write some Java
s
cript to accept that custom form's
website. You'll need to write some Java
S
cript to accept that custom form's
login credentials, then you can pass those credentials (``jid`` and
login credentials, then you can pass those credentials (``jid`` and
``password``) to ``converse.initialize`` to start converse.js and log the user
``password``) to ``converse.initialize`` to start converse.js and log the user
into their XMPP account.
into their XMPP account.
...
@@ -1341,7 +1341,7 @@ xhr_custom_status
...
@@ -1341,7 +1341,7 @@ xhr_custom_status
* Default: ``false``
* Default: ``false``
.. note::
.. note::
XHR stands for XMLHTTPRequest, and is meant here in the AJAX sense (Asynchronous Java
s
cript and XML).
XHR stands for XMLHTTPRequest, and is meant here in the AJAX sense (Asynchronous Java
S
cript and XML).
This option will let converse.js make an AJAX POST with your changed custom chat status to a
This option will let converse.js make an AJAX POST with your changed custom chat status to a
remote server.
remote server.
...
@@ -1350,7 +1350,7 @@ xhr_custom_status_url
...
@@ -1350,7 +1350,7 @@ xhr_custom_status_url
---------------------
---------------------
.. note::
.. note::
XHR stands for XMLHTTPRequest, and is meant here in the AJAX sense (Asynchronous Java
s
cript and XML).
XHR stands for XMLHTTPRequest, and is meant here in the AJAX sense (Asynchronous Java
S
cript and XML).
* Default: Empty string
* Default: Empty string
...
@@ -1367,7 +1367,7 @@ xhr_user_search
...
@@ -1367,7 +1367,7 @@ xhr_user_search
* Default: ``false``
* Default: ``false``
.. note::
.. note::
XHR stands for XMLHTTPRequest, and is meant here in the AJAX sense (Asynchronous Java
s
cript and XML).
XHR stands for XMLHTTPRequest, and is meant here in the AJAX sense (Asynchronous Java
S
cript and XML).
There are two ways to add users.
There are two ways to add users.
...
@@ -1392,7 +1392,7 @@ xhr_user_search_url
...
@@ -1392,7 +1392,7 @@ xhr_user_search_url
-------------------
-------------------
.. note::
.. note::
XHR stands for XMLHTTPRequest, and is meant here in the AJAX sense (Asynchronous Java
s
cript and XML).
XHR stands for XMLHTTPRequest, and is meant here in the AJAX sense (Asynchronous Java
S
cript and XML).
* Default: Empty string
* Default: Empty string
...
...
docs/source/developer_api.rst
View file @
97ccb6c4
...
@@ -50,7 +50,7 @@ Public API methods
...
@@ -50,7 +50,7 @@ Public API methods
==================
==================
Publich API methods are those methods that are accessible on the global
Publich API methods are those methods that are accessible on the global
``window.converse`` object. They are public, because any Java
s
cript in the page
``window.converse`` object. They are public, because any Java
S
cript in the page
can call them. Public methods therefore don't expose any sensitive or closured
can call them. Public methods therefore don't expose any sensitive or closured
data. To do that, you'll need to create a plugin, which has access to the
data. To do that, you'll need to create a plugin, which has access to the
private API method.
private API method.
...
@@ -325,7 +325,7 @@ room under the ``with`` key.
...
@@ -325,7 +325,7 @@ room under the ``with`` key.
The ``start`` and ``end`` parameters are used to query for messages
The ``start`` and ``end`` parameters are used to query for messages
within a certain timeframe. The passed in date values may either be ISO8601
within a certain timeframe. The passed in date values may either be ISO8601
formatted date strings, or Java
s
cript Date objects.
formatted date strings, or Java
S
cript Date objects.
.. code-block:: javascript
.. code-block:: javascript
...
@@ -1070,7 +1070,7 @@ Example:
...
@@ -1070,7 +1070,7 @@ Example:
The **listen** grouping
The **listen** grouping
-----------------------
-----------------------
Converse.js emits events to which you can subscribe from your own Java
s
cript.
Converse.js emits events to which you can subscribe from your own Java
S
cript.
Concerning events, the following methods are available under the "listen"
Concerning events, the following methods are available under the "listen"
grouping:
grouping:
...
...
docs/source/developer_guidelines.rst
View file @
97ccb6c4
...
@@ -9,7 +9,7 @@ Developer guidelines
...
@@ -9,7 +9,7 @@ Developer guidelines
:depth: 2
:depth: 2
:local:
:local:
If you want to work with the non-minified Java
s
cript and CSS files you'll soon
If you want to work with the non-minified Java
S
cript and CSS files you'll soon
notice that there are references to a missing *node_modules* directory.
notice that there are references to a missing *node_modules* directory.
Please follow the instructions below to create these directories and fetch Converse's
Please follow the instructions below to create these directories and fetch Converse's
3rd-party dependencies.
3rd-party dependencies.
...
@@ -97,7 +97,7 @@ Without AMD and require.js
...
@@ -97,7 +97,7 @@ Without AMD and require.js
Converse.js can also be used without require.js. If you for some reason prefer
Converse.js can also be used without require.js. If you for some reason prefer
to use it this way, please refer to
to use it this way, please refer to
`non_amd.html <https://github.com/jcbrand/converse.js/blob/master/non_amd.html>`_
`non_amd.html <https://github.com/jcbrand/converse.js/blob/master/non_amd.html>`_
for an example of how and in what order all the Java
s
cript files that converse.js
for an example of how and in what order all the Java
S
cript files that converse.js
depends on need to be loaded.
depends on need to be loaded.
Brief description of converse.js's dependencies
Brief description of converse.js's dependencies
...
...
docs/source/features.rst
View file @
97ccb6c4
...
@@ -21,7 +21,7 @@ The OTR protocol not only **encrypts your messages**, it provides ways to
...
@@ -21,7 +21,7 @@ The OTR protocol not only **encrypts your messages**, it provides ways to
**plausible deniability** and **perfect forward secrecy** by generating
**plausible deniability** and **perfect forward secrecy** by generating
new encryption keys for each conversation.
new encryption keys for each conversation.
In its current state, Java
s
cript cryptography is fraught with dangers and
In its current state, Java
S
cript cryptography is fraught with dangers and
challenges that make it impossible to reach the same standard of security that
challenges that make it impossible to reach the same standard of security that
is available with native "desktop" software.
is available with native "desktop" software.
...
@@ -29,8 +29,8 @@ This is due to its runtime malleability, the way it is "installed" (e.g.
...
@@ -29,8 +29,8 @@ This is due to its runtime malleability, the way it is "installed" (e.g.
served) and the browser's lack of cryptographic primitives needed to implement
served) and the browser's lack of cryptographic primitives needed to implement
secure crypto.
secure crypto.
For harsh but fairly valid criticism of Java
s
cript cryptography, read:
For harsh but fairly valid criticism of Java
S
cript cryptography, read:
`Java
s
cript Cryptography Considered Harmful <http://www.matasano.com/articles/javascript-cryptography/>`_.
`Java
S
cript Cryptography Considered Harmful <http://www.matasano.com/articles/javascript-cryptography/>`_.
To get an idea on how this applies to OTR support in Converse.js, please read
To get an idea on how this applies to OTR support in Converse.js, please read
`my thoughts on it <https://opkode.com/media/blog/2013/11/11/conversejs-otr-support>`_.
`my thoughts on it <https://opkode.com/media/blog/2013/11/11/conversejs-otr-support>`_.
...
...
docs/source/index.rst
View file @
97ccb6c4
...
@@ -23,7 +23,7 @@ Introduction
...
@@ -23,7 +23,7 @@ Introduction
============
============
Converse.js is a free and open-source `XMPP <http://xmpp.org/about-xmpp/>`_
Converse.js is a free and open-source `XMPP <http://xmpp.org/about-xmpp/>`_
chat client written in Java
s
cript which can be tightly integrated into any website.
chat client written in Java
S
cript which can be tightly integrated into any website.
The benefit of using converse.js as opposed to relying on a SaaS
The benefit of using converse.js as opposed to relying on a SaaS
(software-as-a-service) solution, is that your users can have a much more
(software-as-a-service) solution, is that your users can have a much more
...
...
docs/source/plugin_development.rst
View file @
97ccb6c4
...
@@ -14,24 +14,36 @@ Writing a plugin
...
@@ -14,24 +14,36 @@ Writing a plugin
Introduction
Introduction
------------
------------
Developers are able to extend and override the objects, functions and the
Converse.js is exposes a plugin architecture which allows developers to modify
Backbone models and views that make up converse.js by means of writing plugins.
and extend its functionality.
Specifically, plugins enable developers to extend and override existing objects,
functions and `Backbone <http://backbonejs.org/>`_ models and views that make up
Converse.js, and also give them the ability to write new models and views.
Various core features of Converse.js, such as
`Message Archive Management <https://xmpp.org/extensions/xep-0313.html>`_ and
`Group chats <https://xmpp.org/extensions/xep-0045.html>`_ are implemented
as plugins, thereby showing their power and flexibility.
Converse.js uses `pluggable.js <https://github.com/jcbrand/pluggable.js/>`_ as
Converse.js uses `pluggable.js <https://github.com/jcbrand/pluggable.js/>`_ as
its plugin architecture.
its plugin architecture.
To understand how this plugin architecture works, please read the
To
more deeply
understand how this plugin architecture works, please read the
`pluggable.js documentation <https://jcbrand.github.io/pluggable.js/>`_
`pluggable.js documentation <https://jcbrand.github.io/pluggable.js/>`_
and to understand its inner workins, please refer to the `annotated source code
and to understand its inner workins, please refer to the `annotated source code
<https://jcbrand.github.io/pluggable.js/docs/pluggable.html>`_.
<https://jcbrand.github.io/pluggable.js/docs/pluggable.html>`_.
Below you'll find an example plugin. Because convers.js is only Javascript,
Playing with a Converse.js plugin in JSFiddle
HTML and CSS (with no backend code required like PHP, Python or Ruby) it runs
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
fine in JSFiddle.
Because Converse.js consists only of JavaScript, HTML and CSS (with no backend
code required like PHP, Python or Ruby) it runs fine in JSFiddle.
Here's an Fiddle with a
plugin that calls `alert` when the plugin
gets
Here's an Fiddle with a
Converse.js plugin that calls `alert` once it
gets
initialized and
when a message gets rendered: https://jsfiddle.net/4drfaok0/15/
initialized and
also when a chat message gets rendered:
https://jsfiddle.net/4drfaok0/15/
Registering a plugin
Registering a plugin
--------------------
--------------------
...
@@ -234,7 +246,7 @@ A full example plugin
...
@@ -234,7 +246,7 @@ A full example plugin
(function (root, factory) {
(function (root, factory) {
if (typeof define === 'function' && define.amd) {
if (typeof define === 'function' && define.amd) {
// AMD. Register as a module called "myplugin"
// AMD. Register as a module called "myplugin"
define("myplugin
", ["converse"], factory);
define("<%= name %>
", ["converse"], factory);
} else {
} else {
// Browser globals. If you're not using a module loader such as require.js,
// Browser globals. If you're not using a module loader such as require.js,
// then this line below executes. Make sure that your plugin's <script> tag
// then this line below executes. Make sure that your plugin's <script> tag
...
@@ -256,121 +268,130 @@ A full example plugin
...
@@ -256,121 +268,130 @@ A full example plugin
moment = converse.env.moment;
moment = converse.env.moment;
// The following line registers your plugin.
// The following line registers your plugin.
converse.plugins.add('myplugin', {
converse.plugins.add("<%= name %>", {
initialize: function () {
/* Optional dependencies are other plugins which might be
// Converse.js's plugin mechanism will call the initialize
* overridden or relied upon, and therefore need to be loaded before
// method on any plugin (if it exists) as soon as the plugin has
* this plugin. They are called "optional" because they might not be
// been loaded.
* available, in which case any overrides applicable to them will be
* ignored.
*
* NB: These plugins need to have already been loaded via require.js.
*
* It's possible to make optional dependencies non-optional.
* If the setting "strict_plugin_dependencies" is set to true,
* an error will be raised if the plugin is not found.
*/
'optional_dependencies': [],
/* Converse.js's plugin mechanism will call the initialize
* method on any plugin (if it exists) as soon as the plugin has
* been loaded.
*/
'initialize': function () {
/* Inside this method, you have access to the private
* `_converse` object.
*/
var _converse = this._converse;
var _converse = this._converse;
_converse.log("The <%= name %> plugin is being initialized");
// Inside this method, you have access to the closured
// _converse object, from which
you can get any configuration
/* From the `_converse` object
you can get any configuration
//
options that the user might have passed in via
*
options that the user might have passed in via
// converse.initialize
. These values are stored in the
* `converse.initialize`
. These values are stored in the
//
"user_settings" attribute.
*
"user_settings" attribute.
*
// We
can also specify new configuration settings for this
* You
can also specify new configuration settings for this
//
plugin, or override the default values of existing
*
plugin, or override the default values of existing
//
configuration settings. This is done like so:
*
configuration settings. This is done like so:
*/
_converse.api.settings.update({
_converse.api.settings.update({
'initialize_message': 'Initialized', // New configuration setting
'initialize_message': 'Initializing <%= name %>!'
'auto_subscribe': true, // New default value for an
// existing "core" configuration setting
});
});
// The user can then pass in values for the configuration
/* The user can then pass in values for the configuration
// settings when `converse.initialize` gets called.
* settings when `converse.initialize` gets called.
// For example:
* For example:
//
*
// converse.initialize({
* converse.initialize({
// "initialize_message": "My plugin has been initialized"
* "initialize_message": "My plugin has been initialized"
// });
* });
//
*
// And the configuration setting is then available via the
* And the configuration setting is then available via the
// `user_settings` attribute:
* `user_settings` attribute:
*/
// alert(this._converse.user_settings.initialize_message);
alert(this._converse.user_settings.initialize_message);
// Besides `_converse.api.settings.update`, there is also a
/* Besides `_converse.api.settings.update`, there is also a
// `_converse.api.promises.add` method, which allows you to
* `_converse.api.promises.add` method, which allows you to
// add new promises that your plugin is obligated to fulfill.
* add new promises that your plugin is obligated to fulfill.
*
// This method takes a string or a list of strings which
* This method takes a string or a list of strings which
// represent the promise names.
* represent the promise names:
*
_converse.api.promises.add('operationCompleted');
* _converse.api.promises.add('myPromise');
*
// Your plugin should then, when appropriate, resolve the
* Your plugin should then, when appropriate, resolve the
// promise by calling `_converse.api.emit`, which will also
* promise by calling `_converse.api.emit`, which will also
// emit an event with the same name as the promise.
* emit an event with the same name as the promise.
// For example:
* For example:
// _converse.api.emit('operationCompleted');
*
//
* _converse.api.emit('operationCompleted');
// Other plugins can then either listen for the event
*
// `operationCompleted` like so:
* Other plugins can then either listen for the event
// `_converse.api.listen.on('operationCompleted', function { ... });`
* `operationCompleted` like so:
//
*
// or they can wait for the promise to be fulfilled like so:
* _converse.api.listen.on('operationCompleted', function { ... });
// `_converse.api.waitUntil('operationCompleted', function { ... });`
*
* or they can wait for the promise to be fulfilled like so:
*
* _converse.api.waitUntil('operationCompleted', function { ... });
*/
},
},
// Optional dependencies are other plugins which might be
/* If you want to override some function or a Backbone model or
// overridden or relied upon, and therefore need to be loaded before
* view defined elsewhere in converse.js, then you do that under
// this plugin. They are called "optional" because they might not be
* the "overrides" namespace.
// available, in which case any overrides applicable to them will be
*/
// ignored.
'overrides': {
/* For example, the private *_converse* object has a
// It's possible however to make optional dependencies non-optional.
* method "onConnected". You can override that method as follows:
// If the setting "strict_plugin_dependencies" is set to true,
*/
// an error will be raised if the plugin is not found.
'onConnected': function () {
//
// NB: These plugins need to have already been loaded via require.js.
optional_dependencies: [],
overrides: {
// If you want to override some function or a Backbone model or
// view defined elsewhere in converse.js, then you do that under
// this "overrides" namespace.
// For example, the inner protected *_converse* object has a
// method "onConnected". You can override that method as follows:
onConnected: function () {
// Overrides the onConnected method in converse.js
// Overrides the onConnected method in converse.js
// Top-level functions in "overrides" are bound to the
// Top-level functions in "overrides" are bound to the
// inner "_converse" object.
// inner "_converse" object.
var _converse = this;
var _converse = this;
// Your custom code comes here.
// Your custom code can come here ...
// ...
// You can access the original function being overridden
// You can access the original function being overridden
// via the __super__ attribute.
// via the __super__ attribute.
// Make sure to pass on the arguments supplied to this
// Make sure to pass on the arguments supplied to this
// function and also to apply the proper "this" object.
// function and also to apply the proper "this" object.
_converse.__super__.onConnected.apply(this, arguments);
_converse.__super__.onConnected.apply(this, arguments);
// Your custom code can come here ...
},
},
XMPPStatus: {
/* Override converse.js's XMPPStatus Backbone model so that we can override the
// Override converse.js's XMPPStatus Backbone model so that we can override the
* function that sends out the presence stanza.
// function that sends out the presence stanza.
*/
sendPresence: function (type, status_message, jid) {
'XMPPStatus': {
'sendPresence': function (type, status_message, jid) {
// The "_converse" object is available via the __super__
// The "_converse" object is available via the __super__
// attribute.
// attribute.
var _converse = this.__super__._converse;
var _converse = this.__super__._converse;
// Custom code can come here
// Custom code can come here ...
// ...
// You can call the original overridden method, by
// You can call the original overridden method, by
// accessing it via the __super__ attribute.
// accessing it via the __super__ attribute.
// When calling it, you need to apply the proper
// When calling it, you need to apply the proper
// context as reference by the "this" variable.
// context as reference by the "this" variable.
this.__super__.sendPresence.apply(this, arguments);
this.__super__.sendPresence.apply(this, arguments);
// Custom code can come here ...
}
}
}
}
}
}
...
...
docs/source/quickstart.rst
View file @
97ccb6c4
...
@@ -13,7 +13,7 @@ Use the content delivery network
...
@@ -13,7 +13,7 @@ Use the content delivery network
--------------------------------
--------------------------------
Converse.js has a `CDN <https://en.wikipedia.org/wiki/Content_delivery_network>`_, provided by `KeyCDN <http://keycdn.com/>`_,
Converse.js has a `CDN <https://en.wikipedia.org/wiki/Content_delivery_network>`_, provided by `KeyCDN <http://keycdn.com/>`_,
which hosts its Java
s
cript and CSS files.
which hosts its Java
S
cript and CSS files.
The latest versions of these files are available at these URLs:
The latest versions of these files are available at these URLs:
...
@@ -44,7 +44,7 @@ Initializing Converse.js
...
@@ -44,7 +44,7 @@ Initializing Converse.js
You'll then need to initialize Converse.js with configuration settings relevant to your requirements.
You'll then need to initialize Converse.js with configuration settings relevant to your requirements.
Refer to the :ref:`configuration-settings` section for info on all the available configuration settings.
Refer to the :ref:`configuration-settings` section for info on all the available configuration settings.
To quickly get started, you can put the following Java
s
cript code at the
To quickly get started, you can put the following Java
S
cript code at the
bottom of your page (after the closing *</body>* element)::
bottom of your page (after the closing *</body>* element)::
<script>
<script>
...
@@ -75,7 +75,7 @@ for an example of this build being used. There's an additional CSS file called
...
@@ -75,7 +75,7 @@ for an example of this build being used. There's an additional CSS file called
``mobile.min.css`` which should be used with the mobile build.
``mobile.min.css`` which should be used with the mobile build.
When you load `conversejs.org <https://conversejs.org>`_ with a mobile device
When you load `conversejs.org <https://conversejs.org>`_ with a mobile device
then the mobile Java
s
cript build and its CSS will be used.
then the mobile Java
S
cript build and its CSS will be used.
Excluding 3rd party dependencies
Excluding 3rd party dependencies
--------------------------------
--------------------------------
...
...
docs/source/security.rst
View file @
97ccb6c4
...
@@ -57,7 +57,7 @@ Addititional measures
...
@@ -57,7 +57,7 @@ Addititional measures
Besides the measures mentioned above, integrators and hosts can also take
Besides the measures mentioned above, integrators and hosts can also take
further security precautions.
further security precautions.
The most effective is to avoid serving untrusted 3rd party Java
s
cript (e.g.
The most effective is to avoid serving untrusted 3rd party Java
S
cript (e.g.
advertisements and analytics).
advertisements and analytics).
Another option is to forego the use of a global ``converse`` object (which
Another option is to forego the use of a global ``converse`` object (which
...
...
docs/source/style_guide.rst
View file @
97ccb6c4
...
@@ -14,10 +14,10 @@ Software Style Guide
...
@@ -14,10 +14,10 @@ Software Style Guide
rely on a transpiler and still support older browsers.
rely on a transpiler and still support older browsers.
Most of the style guide recommendations here come from Douglas Crockford's book
Most of the style guide recommendations here come from Douglas Crockford's book
`Java
s
cript, the good parts <http://shop.oreilly.com/product/9780596517748.do>`_
`Java
S
cript, the good parts <http://shop.oreilly.com/product/9780596517748.do>`_
This style guide is fairly opinionated. Some of these opinions perhaps don't
This style guide is fairly opinionated. Some of these opinions perhaps don't
conform to your expectations on how Java
s
cript code should look like.
conform to your expectations on how Java
S
cript code should look like.
I apologize for that. However, for the sake of sanity, consistency and having
I apologize for that. However, for the sake of sanity, consistency and having
code that is pleasing to the eye, please stick to these guidelines.
code that is pleasing to the eye, please stick to these guidelines.
...
@@ -103,7 +103,7 @@ and method invocations.
...
@@ -103,7 +103,7 @@ and method invocations.
Checking for equality
Checking for equality
---------------------
---------------------
Java
s
cript has a strict ``===`` and less strict ``==`` equality operator. The
Java
S
cript has a strict ``===`` and less strict ``==`` equality operator. The
stricter equality operator also does type checking. To avoid subtle bugs when
stricter equality operator also does type checking. To avoid subtle bugs when
doing comparisons, always use the strict equality check.
doing comparisons, always use the strict equality check.
...
...
docs/source/theming.rst
View file @
97ccb6c4
...
@@ -71,7 +71,7 @@ Creating dist files
...
@@ -71,7 +71,7 @@ Creating dist files
===================
===================
Once you've themed converse.js, you'll want to create new minified distribution
Once you've themed converse.js, you'll want to create new minified distribution
files of all the Java
s
cript and CSS.
files of all the Java
S
cript and CSS.
Please refer to the :doc:`builds` section for information on how this is done.
Please refer to the :doc:`builds` section for information on how this is done.
docs/source/translations.rst
View file @
97ccb6c4
...
@@ -59,7 +59,7 @@ translated into, do the following
...
@@ -59,7 +59,7 @@ translated into, do the following
Please make sure to add the following attributes at the top of the file (under
Please make sure to add the following attributes at the top of the file (under
*Content-Transfer-Encoding*). They are required as configuration settings for Jed,
*Content-Transfer-Encoding*). They are required as configuration settings for Jed,
the Java
s
cript translations library that we're using.
the Java
S
cript translations library that we're using.
.. code-block:: po
.. code-block:: po
...
@@ -90,7 +90,7 @@ The resulting `.po` file is then what gets translated.
...
@@ -90,7 +90,7 @@ The resulting `.po` file is then what gets translated.
-----------------------------------------------------
-----------------------------------------------------
Generating a Java
s
cript file from a translations file
Generating a Java
S
cript file from a translations file
-----------------------------------------------------
-----------------------------------------------------
Unfortunately `Jed <http://slexaxton.github.io/Jed>`_, which we use for
Unfortunately `Jed <http://slexaxton.github.io/Jed>`_, which we use for
...
...
docs/source/troubleshooting.rst
View file @
97ccb6c4
...
@@ -42,13 +42,13 @@ more likely on the XMPP server's end (perhaps a misconfiguration?). If they
...
@@ -42,13 +42,13 @@ more likely on the XMPP server's end (perhaps a misconfiguration?). If they
**are** logged, then there might be a bug or misconfiguration in Converse.js.
**are** logged, then there might be a bug or misconfiguration in Converse.js.
Conflicts with other Java
s
cript libraries
Conflicts with other Java
S
cript libraries
=========================================
=========================================
Problem:
Problem:
---------
---------
You are using other Java
s
cript libraries (like JQuery plugins), and
You are using other Java
S
cript libraries (like JQuery plugins), and
get errors like these in your browser console::
get errors like these in your browser console::
Uncaught TypeError: Object [object Object] has no method 'xxx' from example.js
Uncaught TypeError: Object [object Object] has no method 'xxx' from example.js
...
...
index.html
View file @
97ccb6c4
...
@@ -12,11 +12,11 @@
...
@@ -12,11 +12,11 @@
<link
type=
"text/css"
rel=
"stylesheet"
media=
"screen"
href=
"css/bootstrap.min.css"
/>
<link
type=
"text/css"
rel=
"stylesheet"
media=
"screen"
href=
"css/bootstrap.min.css"
/>
<link
type=
"text/css"
rel=
"stylesheet"
media=
"screen"
href=
"css/font-awesome.min.css"
/>
<link
type=
"text/css"
rel=
"stylesheet"
media=
"screen"
href=
"css/font-awesome.min.css"
/>
<link
type=
"text/css"
rel=
"stylesheet"
media=
"screen"
href=
"css/theme.min.css"
/>
<link
type=
"text/css"
rel=
"stylesheet"
media=
"screen"
href=
"css/theme.min.css"
/>
<link
type=
"text/css"
rel=
"stylesheet"
media=
"screen"
href=
"css/converse.css"
/>
<script
type=
"text/javascript"
src=
"analytics.js"
></script>
<script
type=
"text/javascript"
src=
"analytics.js"
></script>
<noscript><p><img
src=
"//stats.opkode.com/piwik.php?idsite=1"
style=
"border:0;"
alt=
""
/></p></noscript>
<noscript><p><img
src=
"//stats.opkode.com/piwik.php?idsite=1"
style=
"border:0;"
alt=
""
/></p></noscript>
<script
src=
"src/website.js"
></script>
<script
src=
"src/website.js"
></script>
<
![
if
gte
IE
11
]
>
<
![
if
gte
IE
11
]
>
<link
type=
"text/css"
rel=
"stylesheet"
media=
"screen"
href=
"css/converse.css"
/>
<script
src=
"dist/converse.min.js"
></script>
<script
src=
"dist/converse.min.js"
></script>
<
![
endif
]
>
<
![
endif
]
>
</head>
</head>
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment