I'm a Java dev completely new to Frontend stuff and currently looking into building a little Vue-App. Herefor I want to make use of a library (called vue-good-table, but pretty much irrelevant I guess).
I downloaded and installed it via npm (npm install --save vue-good-table) and am now trying to make it work with the basic project template provided by the vue-cli looking like this: 1 HelloWorld-component, renamed it to IssueTable.vue being loaded in the Home.vue - view, App.vue as start point and main.js and router.js being there too: Project setup
I have then tried adding the import and Vue.use statement to the main.js file, since it seems to be the place, where imports where already there, so it looks like this:
import Vue from 'vue'
import App from './App.vue'
import router from './router'
import VueGoodTable from 'vue-good-table'
Vue.use(VueGoodTable)
Vue.config.productionTip = false
new Vue({
router,
render: h => h(App)
}).$mount('#app')
This does not make it work and I dont see the table I would expect to see being created in my IssueTable.vue component. Adding the import and Vue.use - lines into the component file itself doesnt seem to work either.
So my question is, what do I have to do to make use of the library?
Thank you very much :)
import 'vue-good-table/dist/vue-good-table.css', you might give it a try. Furthermore the (relevant) code fromIssueTable.vuewould be interesting. - dr_barto