Don't name the modules.

According to the require.js docs this shouldn't be done.
http://requirejs.org/docs/whyamd.html#namedmodules
This commit is contained in:
JC Brand 2017-02-13 14:37:17 +00:00
parent fd2f1c22e4
commit f73a1d3fc0
17 changed files with 28 additions and 43 deletions

View File

@ -6,7 +6,7 @@
//
/*global define */
(function (root, factory) {
define("converse-api", [
define([
"jquery",
"lodash",
"moment_with_locales",

View File

@ -10,7 +10,7 @@
* in XEP-0048.
*/
(function (root, factory) {
define("converse-bookmarks", [
define([
"jquery",
"lodash",
"moment_with_locales",

View File

@ -7,7 +7,7 @@
/*global Backbone, define */
(function (root, factory) {
define("converse-chatview", [
define([
"converse-api",
"tpl!chatbox",
"tpl!new_day",

View File

@ -7,7 +7,7 @@
/*global define, Backbone */
(function (root, factory) {
define("converse-controlbox", [
define([
"converse-api",
"tpl!add_contact_dropdown",
"tpl!add_contact_form",

View File

@ -7,7 +7,7 @@
/*global Backbone, define, window, document */
(function (root, factory) {
define("converse-core", [
define([
"sizzle",
"jquery",
"lodash",

View File

@ -1,13 +1,13 @@
// Converse.js (A browser based XMPP chat client)
// http://conversejs.org
//
// Copyright (c) 2012-2016, Jan-Carel Brand <jc@opkode.com>
// Copyright (c) 2012-2017, Jan-Carel Brand <jc@opkode.com>
// Licensed under the Mozilla Public License (MPLv2)
//
/*global define, window */
(function (root, factory) {
define("converse-dragresize", [
define([
"converse-api",
"tpl!dragresize",
"converse-chatview",

View File

@ -1,13 +1,13 @@
// Converse.js (A browser based XMPP chat client)
// http://conversejs.org
//
// Copyright (c) 2012-2016, Jan-Carel Brand <jc@opkode.com>
// Copyright (c) 2012-2017, Jan-Carel Brand <jc@opkode.com>
// Licensed under the Mozilla Public License (MPLv2)
//
/*global define */
(function (root, factory) {
define("converse-headline", [
define([
"converse-api",
"converse-chatview"
], factory);

View File

@ -1,7 +1,7 @@
// Converse.js (A browser based XMPP chat client)
// http://conversejs.org
//
// Copyright (c) 2012-2016, Jan-Carel Brand <jc@opkode.com>
// Copyright (c) 2012-2017, Jan-Carel Brand <jc@opkode.com>
// Licensed under the Mozilla Public License (MPLv2)
//
/*global define */
@ -9,7 +9,7 @@
// XEP-0059 Result Set Management
(function (root, factory) {
define("converse-mam", [
define([
"converse-api",
"converse-chatview", // Could be made a soft dependency
"converse-muc", // Could be made a soft dependency

View File

@ -1,13 +1,13 @@
// Converse.js (A browser based XMPP chat client)
// http://conversejs.org
//
// Copyright (c) 2012-2016, Jan-Carel Brand <jc@opkode.com>
// Copyright (c) 2012-2017, Jan-Carel Brand <jc@opkode.com>
// Licensed under the Mozilla Public License (MPLv2)
//
/*global Backbone, define, window */
(function (root, factory) {
define("converse-minimize", [
define([
"converse-api",
"tpl!chatbox_minimize",
"tpl!toggle_chats",

View File

@ -6,10 +6,7 @@
//
/*global Backbone */
(function (root, factory) {
define("converse-muc-embedded", [
"converse-api",
"converse-muc"
], factory);
define(["converse-api", "converse-muc"], factory);
}(this, function (converse) {
"use strict";

View File

@ -1,7 +1,7 @@
// Converse.js (A browser based XMPP chat client)
// http://conversejs.org
//
// Copyright (c) 2012-2016, Jan-Carel Brand <jc@opkode.com>
// Copyright (c) 2012-2017, Jan-Carel Brand <jc@opkode.com>
// Licensed under the Mozilla Public License (MPLv2)
//
/*global Backbone, define */
@ -10,7 +10,7 @@
* specified in XEP-0045 Multi-user chat.
*/
(function (root, factory) {
define("converse-muc", [
define([
"converse-api",
"tpl!chatarea",
"tpl!chatroom",

View File

@ -1,13 +1,13 @@
// Converse.js (A browser based XMPP chat client)
// http://conversejs.org
//
// Copyright (c) 2012-2016, Jan-Carel Brand <jc@opkode.com>
// Copyright (c) 2012-2017, Jan-Carel Brand <jc@opkode.com>
// Licensed under the Mozilla Public License (MPLv2)
//
/*global define */
(function (root, factory) {
define("converse-notification", ["converse-api"], factory);
define(["converse-api"], factory);
}(this, function (converse) {
"use strict";
var $ = converse.env.jQuery,

View File

@ -1,7 +1,7 @@
// Converse.js (A browser based XMPP chat client)
// http://conversejs.org
//
// Copyright (c) 2012-2016, Jan-Carel Brand <jc@opkode.com>
// Copyright (c) 2012-2017, Jan-Carel Brand <jc@opkode.com>
// Licensed under the Mozilla Public License (MPLv2)
//
/*global Backbone, define, window, crypto, CryptoJS */
@ -10,11 +10,7 @@
* encryption of one-on-one chat messages.
*/
(function (root, factory) {
define("converse-otr", [
"otr",
"converse-api",
"tpl!toolbar_otr"
], factory);
define(["otr", "converse-api", "tpl!toolbar_otr"], factory);
}(this, function (otr, converse, tpl_toolbar_otr) {
"use strict";
// Strophe methods for building stanzas

View File

@ -1,7 +1,7 @@
// Converse.js (A browser based XMPP chat client)
// http://conversejs.org
//
// Copyright (c) 2012-2016, Jan-Carel Brand <jc@opkode.com>
// Copyright (c) 2012-2017, Jan-Carel Brand <jc@opkode.com>
// Licensed under the Mozilla Public License (MPLv2)
//
/*global define */
@ -10,10 +10,7 @@
* as specified in XEP-0199 XMPP Ping.
*/
(function (root, factory) {
define("converse-ping", [
"converse-api",
"strophe.ping"
], factory);
define(["converse-api", "strophe.ping"], factory);
}(this, function (converse) {
"use strict";
// Strophe methods for building stanzas

View File

@ -1,7 +1,7 @@
// Converse.js (A browser based XMPP chat client)
// http://conversejs.org
//
// Copyright (c) 2012-2016, Jan-Carel Brand <jc@opkode.com>
// Copyright (c) 2012-2017, Jan-Carel Brand <jc@opkode.com>
// Licensed under the Mozilla Public License (MPLv2)
//
/*global Backbone, define */
@ -10,8 +10,7 @@
* as specified in XEP-0077.
*/
(function (root, factory) {
define("converse-register", [
"converse-api",
define(["converse-api",
"tpl!form_username",
"tpl!register_panel",
"tpl!register_tab",

View File

@ -1,14 +1,13 @@
// Converse.js (A browser based XMPP chat client)
// http://conversejs.org
//
// Copyright (c) 2012-2016, Jan-Carel Brand <jc@opkode.com>
// Copyright (c) 2012-2017, Jan-Carel Brand <jc@opkode.com>
// Licensed under the Mozilla Public License (MPLv2)
//
/*global Backbone, define */
(function (root, factory) {
define("converse-rosterview", [
"converse-api",
define(["converse-api",
"tpl!group_header",
"tpl!pending_contact",
"tpl!requesting_contact",

View File

@ -1,16 +1,13 @@
// Converse.js (A browser based XMPP chat client)
// http://conversejs.org
//
// Copyright (c) 2012-2016, Jan-Carel Brand <jc@opkode.com>
// Copyright (c) 2012-2017, Jan-Carel Brand <jc@opkode.com>
// Licensed under the Mozilla Public License (MPLv2)
//
/*global define */
(function (root, factory) {
define("converse-vcard", [
"converse-api",
"strophe.vcard",
], factory);
define(["converse-api", "strophe.vcard"], factory);
}(this, function (converse) {
"use strict";
var Strophe = converse.env.Strophe,