Commit c855d2f4 authored by JC Brand's avatar JC Brand

Updates #2350 Avoid bundling Strophe twice

by not importing Strophe outside of @converse/headless
parent 4ece50d0
......@@ -4,7 +4,6 @@
* @license Mozilla Public License (MPLv2)
*/
import './polyfill';
import 'strophe.js/src/websocket';
import Storage from '@converse/skeletor/src/storage.js';
import advancedFormat from 'dayjs/plugin/advancedFormat';
import dayjs from 'dayjs';
......
import log from "../log.js";
import sizzle from 'sizzle';
import u from '@converse/headless/utils/core';
import { Strophe } from 'strophe.js/src/core';
import { Strophe } from 'strophe.js/src/strophe';
import { _converse, api, clearSession, tearDown } from "../core.js";
import { debounce, isElement } from 'lodash';
......
......@@ -3,14 +3,12 @@
* @license Mozilla Public License (MPLv2)
* @description This is the core utilities module.
*/
import * as strophe from 'strophe.js/src/core';
import { Strophe } from 'strophe.js/src/strophe';
import { Model } from '@converse/skeletor/src/model.js';
import { compact, last, isElement, isObject } from "lodash-es";
import log from "@converse/headless/log";
import sizzle from "sizzle";
const Strophe = strophe.default.Strophe;
/**
* The utils object
* @namespace u
......
import * as strophe from 'strophe.js/src/core';
import { Strophe, $msg } from 'strophe.js/src/strophe';
import dayjs from 'dayjs';
import sizzle from 'sizzle';
import u from '@converse/headless/utils/core';
import log from "../log";
import { _converse, api } from "@converse/headless/core";
const Strophe = strophe.default.Strophe;
const $msg = strophe.default.$msg;
const { NS } = Strophe;
......
import tpl_add_muc from "./templates/add-muc.js";
import BootstrapModal from "./base.js";
import { Strophe } from 'strophe.js/src/strophe';
import { __ } from '../i18n';
import { _converse, api, converse } from "@converse/headless/core";
const u = converse.env.utils;
const { Strophe } = converse.env;
export default BootstrapModal.extend({
......
......@@ -5,11 +5,11 @@ import st from "@converse/headless/utils/stanza";
import tpl_list_chatrooms_modal from "./templates/muc-list.js";
import tpl_room_description from "templates/room_description.html";
import tpl_spinner from "templates/spinner.js";
import { Strophe, $iq } from 'strophe.js/src/strophe';
import { __ } from '../i18n';
import { _converse, api, converse } from "@converse/headless/core";
import { head } from "lodash-es";
const { Strophe, $iq } = converse.env;
const u = converse.env.utils;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment