summaryrefslogtreecommitdiff
path: root/app
diff options
context:
space:
mode:
authorAlfredo Sumaran <alfredo@gitlab.com>2017-05-04 20:49:07 -0500
committerAlfredo Sumaran <alfredo@gitlab.com>2017-05-04 20:49:07 -0500
commitd67ab685350005b83a12988845b7fb87c613b472 (patch)
treec396164baf4dc695280e846a9ac6744527bff6ba /app
parent1dc2b4693e4a58c94e556ae219ae6200044f95dc (diff)
downloadgitlab-ce-d67ab685350005b83a12988845b7fb87c613b472.tar.gz
Set Groups Vue app for Dashboard page
Diffstat (limited to 'app')
-rw-r--r--app/assets/javascripts/groups/index.js12
-rw-r--r--app/assets/javascripts/groups/stores/groups_store.js5
-rw-r--r--app/views/dashboard/groups/index.html.haml1
3 files changed, 16 insertions, 2 deletions
diff --git a/app/assets/javascripts/groups/index.js b/app/assets/javascripts/groups/index.js
index c0e083ef635..934e3b8e580 100644
--- a/app/assets/javascripts/groups/index.js
+++ b/app/assets/javascripts/groups/index.js
@@ -1,3 +1,11 @@
+import Vue from 'vue';
+import GroupsStore from './stores/groups_store';
+
$(() => {
- // Groups bundle
-}); \ No newline at end of file
+ const groupsStore = new GroupsStore();
+
+ const GroupsApp = new Vue({
+ el: document.querySelector('.js-groups-list-holder'),
+ data: groupsStore,
+ });
+});
diff --git a/app/assets/javascripts/groups/stores/groups_store.js b/app/assets/javascripts/groups/stores/groups_store.js
new file mode 100644
index 00000000000..f62f419ac1b
--- /dev/null
+++ b/app/assets/javascripts/groups/stores/groups_store.js
@@ -0,0 +1,5 @@
+export default class GroupsStore {
+ constructor() {
+ this.groups = [];
+ }
+}
diff --git a/app/views/dashboard/groups/index.html.haml b/app/views/dashboard/groups/index.html.haml
index bf1013c685b..af9f9b1b363 100644
--- a/app/views/dashboard/groups/index.html.haml
+++ b/app/views/dashboard/groups/index.html.haml
@@ -2,6 +2,7 @@
- header_title "Groups", dashboard_groups_path
= render 'dashboard/groups_head'
+= page_specific_javascript_bundle_tag('common_vue')
= page_specific_javascript_bundle_tag('groups')
- if @groups.empty?