From 178f21e6c8018edda3116f4391296036f589db78 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Kevin=20Midb=C3=B8e?= Date: Sat, 16 Nov 2019 21:02:52 +0100 Subject: [PATCH 1/4] Working youtube iframe player --- frontend/components/Player.vue | 82 +++++++++++++++++++++++++++++++++- 1 file changed, 81 insertions(+), 1 deletion(-) diff --git a/frontend/components/Player.vue b/frontend/components/Player.vue index 7d1c910a..8543837f 100644 --- a/frontend/components/Player.vue +++ b/frontend/components/Player.vue @@ -1,13 +1,93 @@ + + \ No newline at end of file From cb0d3633ac82ed7cf8f024e001803ef9f4becf6f Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Kevin=20Midb=C3=B8e?= Date: Sat, 16 Nov 2019 21:03:48 +0100 Subject: [PATCH 2/4] Imported normalize styles into a un-scoped style section of App.vue --- frontend/App.vue | 8 +++++--- frontend/styles/normalize.scss | 5 +++++ 2 files changed, 10 insertions(+), 3 deletions(-) create mode 100644 frontend/styles/normalize.scss diff --git a/frontend/App.vue b/frontend/App.vue index ab83167d..f2f366ac 100644 --- a/frontend/App.vue +++ b/frontend/App.vue @@ -1,7 +1,9 @@ \ No newline at end of file + + + \ No newline at end of file diff --git a/frontend/styles/normalize.scss b/frontend/styles/normalize.scss new file mode 100644 index 00000000..5d531962 --- /dev/null +++ b/frontend/styles/normalize.scss @@ -0,0 +1,5 @@ + +body { + margin: 0; + padding: 0; +} \ No newline at end of file From 3680d9ba4368400491a310243d8d4f05aca5efe8 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Kevin=20Midb=C3=B8e?= Date: Sat, 16 Nov 2019 21:04:00 +0100 Subject: [PATCH 3/4] Started a store --- frontend/main.js | 4 ++-- frontend/modules/playerModule.js | 21 +++++++++++++++++++++ frontend/store.js | 12 ++++++++++++ 3 files changed, 35 insertions(+), 2 deletions(-) create mode 100644 frontend/modules/playerModule.js create mode 100644 frontend/store.js diff --git a/frontend/main.js b/frontend/main.js index da93ebe2..3f8c4349 100644 --- a/frontend/main.js +++ b/frontend/main.js @@ -1,7 +1,7 @@ import Vue from 'vue' import VueRouter from 'vue-router' import router from './routes' -// import store from './store' +import store from './store' import App from './App.vue' @@ -10,7 +10,7 @@ Vue.use(VueRouter) new Vue({ el: '#app', router, - // store, + store, components: { App }, render: h => h(App) }) \ No newline at end of file diff --git a/frontend/modules/playerModule.js b/frontend/modules/playerModule.js new file mode 100644 index 00000000..102a4a73 --- /dev/null +++ b/frontend/modules/playerModule.js @@ -0,0 +1,21 @@ +export default { + namespaced: true, + state: { + player: undefined + }, + getters: { + player: (state) => { + return state.player; + } + }, + mutations: { + SET_PLAYER: (state, player) => { + state.player = player; + } + }, + actios: { + setPlayer({ commit }, player) { + commit('SET_PLAYER', player) + } + } +} diff --git a/frontend/store.js b/frontend/store.js new file mode 100644 index 00000000..076c50ca --- /dev/null +++ b/frontend/store.js @@ -0,0 +1,12 @@ +import Vue from 'vue'; +import Vuex from 'vuex'; + +import playerModule from '@/modules/playerModule'; + +Vue.use(Vuex); + +const store = new Vuex.Store({ + modules: { + playerModule + } +}) \ No newline at end of file From f90cf2132b7bf54a086148d31db998e4acc2d7ca Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Kevin=20Midb=C3=B8e?= Date: Sat, 16 Nov 2019 21:18:13 +0100 Subject: [PATCH 4/4] NO longer opens a new window and changed port 8000 -> 8080. --- config/webpack.config.dev.js | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/config/webpack.config.dev.js b/config/webpack.config.dev.js index db6de142..395ca3a9 100644 --- a/config/webpack.config.dev.js +++ b/config/webpack.config.dev.js @@ -33,9 +33,8 @@ const webpackConfig = merge(commonConfig(true), { compress: true, historyApiFallback: true, hot: true, - open: true, overlay: true, - port: 8000, + port: 8080, stats: { normal: true }