aboutsummaryrefslogtreecommitdiffstats
path: root/apps/weather_status/src/weather-status.js
diff options
context:
space:
mode:
Diffstat (limited to 'apps/weather_status/src/weather-status.js')
-rw-r--r--apps/weather_status/src/weather-status.js22
1 files changed, 9 insertions, 13 deletions
diff --git a/apps/weather_status/src/weather-status.js b/apps/weather_status/src/weather-status.js
index 0e7c5690b90..45c73b87e4a 100644
--- a/apps/weather_status/src/weather-status.js
+++ b/apps/weather_status/src/weather-status.js
@@ -1,14 +1,14 @@
+/**
+ * SPDX-FileCopyrightText: 2016 Nextcloud GmbH and Nextcloud contributors
+ * SPDX-License-Identifier: AGPL-3.0-or-later
+ */
+
+import { getCSPNonce } from '@nextcloud/auth'
import Vue from 'vue'
-import { getRequestToken } from '@nextcloud/auth'
-import { generateUrl } from '@nextcloud/router'
-import App from './App'
+import App from './App.vue'
// eslint-disable-next-line camelcase
-__webpack_nonce__ = btoa(getRequestToken())
-
-// Correct the root of the app for chunk loading
-// eslint-disable-next-line
-__webpack_public_path__ = generateUrl('/apps/weather_status/js/')
+__webpack_nonce__ = getCSPNonce()
Vue.prototype.t = t
@@ -19,10 +19,6 @@ document.addEventListener('DOMContentLoaded', function() {
OCA.Dashboard.registerStatus('weather', (el) => {
const Dashboard = Vue.extend(App)
- return new Dashboard({
- propsData: {
- inline: true,
- },
- }).$mount(el)
+ return new Dashboard().$mount(el)
})
})