Skip to main content
The 2024 Developer Survey results are live! See the results

Questions tagged [vue-component]

Component is a powerful Vue feature that allows extending basic HTML elements to encapsulate reusable code.

vue-component
3,275 questions with no upvoted or accepted answers
9 votes
2 answers
651 views

Creating component programmatically in Nuxt.js

I'm trying to create a nuxt.js component programmatically. I tried the approach below which works in Vue. But it doesn't seem to work in nuxt.js because it instantiates the component on the Vue object....
Max Campbell's user avatar
9 votes
0 answers
1k views

Add Generic Type to Component in vue.js with Typescript

I have a Component in Vue which has a specific set of data. The data is always defined by an Interface in typescript. At this moment, I keep the info about the selected items out of the DataTable ...
Olivier Van Bulck's user avatar
9 votes
0 answers
2k views

How to build a es6 vue-component library using vue-class-component

I am trying to create a vuejs component library in typescript with vue-class-component and vue-property-decorator with the following requirements: The library components should be written in class-...
ShabbY's user avatar
  • 896
8 votes
1 answer
1k views

How do I use Nova components in a custom tool or card?

I'm currently working on a Laravel Nova application in which I need to add a lot of custom tools and cards. I'd like to keep consistency across the whole application, so it makes sense to simply use ...
develpr's user avatar
  • 1,366
8 votes
0 answers
751 views

Integrating an Algolia InstantSearch Vue Component into a Vuetify Data-table

I am building a Vue JS Application, with a Vuetify data-table, and an Algolia InstantSearch Vue Component into it. However currently the data-table, and the InstantSearch index are using different ...
VerySeriousSoftwareEndeavours's user avatar
8 votes
0 answers
2k views

Server side pagination with firestore in vuetify

I am working on project where i want to paginate data from a collection,The collection contains thousands of record,So obysly in that case i can not go through with datatable which renders all the ...
Shakti S's user avatar
  • 351
8 votes
1 answer
2k views

Simulate v-if directive in custom directive

I need to destroy element in custom directive like v-if. (Forbid item creation if the condition fails.) I trying this export const moduleDirective: DirectiveOptions | DirectiveFunction = (el, ...
Mgorunuch's user avatar
  • 666
7 votes
0 answers
746 views

How to use <slot/> as the root element of a Vue component?

I'd like to build a wrapper component, that just adds some JavaScript to the actual component that is passed in, but without creating an extra HTML element. This works, but creates a div as the root ...
Marian Klühspies's user avatar
7 votes
0 answers
574 views

how to configure types for Typescript and Vue 3.0 (bundler and runtime compilation)

I'm following the Vue getting started guide, and would like to make this simple example work: HTML: <div id="counter"> Counter: {{ counter }} </div> Typescript: const Counter =...
lhk's user avatar
  • 29.3k
7 votes
0 answers
1k views

How can we build a UML class diagram for single page vue js component?

I used the UML class diagram for java class but this time, I am developing a web application that uses a single file component. I am asking how can we get a class diagram for this Vue js component. ...
karlos's user avatar
  • 940
7 votes
1 answer
4k views

Vue component script indent rules conflicting

I'm trying to set some ESLint rules to my new Vue project extending both eslint-plugin-vue and airbnb. I could set up everything just fine, except for the tag inside Vue components. The accepted ...
phellipeperin's user avatar
6 votes
0 answers
3k views

Vue: Conditionally allow prop types based on value of another prop

I have a component with the prop value and the prop range. range is of type Boolean and defaults to false. value should be of type String when range is false, and of type Array if range is true. ...
Klausette's user avatar
  • 412
6 votes
1 answer
276 views

Vue.js SFC conditionally include template elements at compile time

Our product has multiple customers, and each have their own customer-specific modifications. Is there a way in a Vue2 template of an SFC to conditionally include or exclude other components at the ...
Spanners's user avatar
6 votes
0 answers
1k views

Laravel Nova Vue component not being rendered

I have a laravel nova package where I define a custom vue component like this: Nova.booting((Vue, router, store) => { Vue.component('my-component', require('./components/MyComponent').default); }...
user3743266's user avatar
  • 1,162
6 votes
1 answer
1k views

Lazy loading translation file in <i18n> tag

I want to reduce my app size and i started from language files. I'm using vue-i18n Single File Components and i can lazy load like this vue-i18n Lazy loading. I read about custom lang blocks, but as i ...
hafer's user avatar
  • 137

15 30 50 per page
1
2 3 4 5
219