Skip to content

Commit

Permalink
Merge pull request #1454 from nextcloud/perf/lazy-load
Browse files Browse the repository at this point in the history
Perf: Improve time to render of Nextcloud via lazy-loading
  • Loading branch information
nickvergessen authored Feb 14, 2023
2 parents c2ee99a + 3ac1324 commit 4986be0
Show file tree
Hide file tree
Showing 14 changed files with 118 additions and 101 deletions.
4 changes: 2 additions & 2 deletions js/notifications-admin-settings.js

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion js/notifications-admin-settings.js.map

Large diffs are not rendered by default.

4 changes: 2 additions & 2 deletions js/notifications-main.js

Large diffs are not rendered by default.

90 changes: 0 additions & 90 deletions js/notifications-main.js.LICENSE.txt
Original file line number Diff line number Diff line change
@@ -1,74 +1,16 @@
/*!
* Spatial Plugin - Adds support for stereo and 3D audio where Web Audio is supported.
*
* howler.js v2.2.3
* howlerjs.com
*
* (c) 2013-2020, James Simpson of GoldFire Studios
* goldfirestudios.com
*
* MIT License
*/

/*!
* howler.js v2.2.3
* howlerjs.com
*
* (c) 2013-2020, James Simpson of GoldFire Studios
* goldfirestudios.com
*
* MIT License
*/

/*!
* Determine if an object is a Buffer
*
* @author Feross Aboukhadijeh <https://feross.org>
* @license MIT
*/

/*!
* The buffer module from node.js, for the browser.
*
* @author Feross Aboukhadijeh <feross@feross.org> <http://feross.org>
* @license MIT
*/

/*!
* The buffer module from node.js, for the browser.
*
* @author Feross Aboukhadijeh <https://feross.org>
* @license MIT
*/

/*!
* Vue.js v2.7.14
* (c) 2014-2022 Evan You
* Released under the MIT License.
*/

/*!
* escape-html
* Copyright(c) 2012-2013 TJ Holowaychuk
* Copyright(c) 2015 Andreas Lubbe
* Copyright(c) 2015 Tiancheng "Timothy" Gu
* MIT Licensed
*/

/*!
* focus-trap 7.2.0
* @license MIT, https://github.com/focus-trap/focus-trap/blob/master/LICENSE
*/

/*!
* tabbable 6.0.1
* @license MIT, https://github.com/focus-trap/tabbable/blob/master/LICENSE
*/

/*! For license information please see NcButton.js.LICENSE.txt */

/*! ieee754. BSD-3-Clause License. Feross Aboukhadijeh <https://feross.org/opensource> */

/**
* @copyright Copyright (c) 2018 Joas Schilling <coding@schilljs.com>
*
Expand All @@ -88,35 +30,3 @@
* along with this program. If not, see <http://www.gnu.org/licenses/>.
*
*/

/**
* @copyright Copyright (c) 2020 Joas Schilling <coding@schilljs.com>
*
* @license AGPL-3.0-or-later
*
* This program is free software: you can redistribute it and/or modify
* it under the terms of the GNU Affero General Public License as
* published by the Free Software Foundation, either version 3 of the
* License, or (at your option) any later version.
*
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU Affero General Public License for more details.
*
* You should have received a copy of the GNU Affero General Public License
* along with this program. If not, see <http://www.gnu.org/licenses/>.
*
*/

//! authors : Tim Wood, Iskren Chernev, Moment.js contributors

//! license : MIT

//! moment.js

//! moment.js locale configuration

//! momentjs.com

//! version : 2.29.4
2 changes: 1 addition & 1 deletion js/notifications-main.js.map

Large diffs are not rendered by default.

Large diffs are not rendered by default.

Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
/**
* @copyright Copyright (c) 2020 Joas Schilling <coding@schilljs.com>
*
* @license AGPL-3.0-or-later
*
* This program is free software: you can redistribute it and/or modify
* it under the terms of the GNU Affero General Public License as
* published by the Free Software Foundation, either version 3 of the
* License, or (at your option) any later version.
*
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU Affero General Public License for more details.
*
* You should have received a copy of the GNU Affero General Public License
* along with this program. If not, see <http://www.gnu.org/licenses/>.
*
*/

Large diffs are not rendered by default.

4 changes: 2 additions & 2 deletions js/notifications-settings.js

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion js/notifications-settings.js.map

Large diffs are not rendered by default.

Large diffs are not rendered by default.

Original file line number Diff line number Diff line change
@@ -0,0 +1,73 @@
/*!
* Spatial Plugin - Adds support for stereo and 3D audio where Web Audio is supported.
*
* howler.js v2.2.3
* howlerjs.com
*
* (c) 2013-2020, James Simpson of GoldFire Studios
* goldfirestudios.com
*
* MIT License
*/

/*!
* howler.js v2.2.3
* howlerjs.com
*
* (c) 2013-2020, James Simpson of GoldFire Studios
* goldfirestudios.com
*
* MIT License
*/

/*!
* Determine if an object is a Buffer
*
* @author Feross Aboukhadijeh <https://feross.org>
* @license MIT
*/

/*!
* The buffer module from node.js, for the browser.
*
* @author Feross Aboukhadijeh <https://feross.org>
* @license MIT
*/

/*!
* Vue.js v2.7.14
* (c) 2014-2022 Evan You
* Released under the MIT License.
*/

/*!
* escape-html
* Copyright(c) 2012-2013 TJ Holowaychuk
* Copyright(c) 2015 Andreas Lubbe
* Copyright(c) 2015 Tiancheng "Timothy" Gu
* MIT Licensed
*/

/*!
* focus-trap 7.2.0
* @license MIT, https://github.com/focus-trap/focus-trap/blob/master/LICENSE
*/

/*!
* tabbable 6.0.1
* @license MIT, https://github.com/focus-trap/tabbable/blob/master/LICENSE
*/

/*! ieee754. BSD-3-Clause License. Feross Aboukhadijeh <https://feross.org/opensource> */

//! authors : Tim Wood, Iskren Chernev, Moment.js contributors

//! license : MIT

//! moment.js

//! moment.js locale configuration

//! momentjs.com

//! version : 2.29.4

Large diffs are not rendered by default.

11 changes: 9 additions & 2 deletions src/main.js
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,6 @@
*/

import Vue from 'vue'
import NotificationsApp from './NotificationsApp.vue'

// Styles
import './styles/styles.scss'
Expand All @@ -30,9 +29,17 @@ Vue.prototype.n = n
Vue.prototype.OC = OC
Vue.prototype.OCA = OCA

// eslint-disable-next-line
__webpack_nonce__ = btoa(OC.requestToken);
// eslint-disable-next-line
__webpack_public_path__ = OC.linkTo('notifications', 'js/');

export default new Vue({
el: '#notifications',
// eslint-disable-next-line vue/match-component-file-name
name: 'NotificationsApp',
render: h => h(NotificationsApp),
components: {
NotificationsApp: () => import(/* webpackPreload: true */'./NotificationsApp.vue'),
},
render: h => h('NotificationsApp'),
})

0 comments on commit 4986be0

Please sign in to comment.