Page 1 of 1

programmaticalluy creating instances of a primevue component

Posted: 08 Mar 2023, 14:05
by Sreens
How to programmatically create instances of a primevue ?
I want a dropdown to be created every time I click a button.

Re: programmaticalluy creating instances of a primevue component

Posted: 09 Mar 2023, 10:35
by bahadirsofuoglu
Hi, You can do local import and use the component in Vue instance. I would like to help more. If you share an example, we can talk about it.

Re: programmaticalluy creating instances of a primevue component

Posted: 14 Mar 2023, 12:43
by Sreens
I have two dropdowns in the page. second dropdown shows up once I select the first one.
When I click button add view I want another instance of the two dropdowns to be created.
If I click the button n times I want n instances to be created to the side of the two dropdowns.

I want to programmatically append the same dropdowns to the dom

Re: programmaticalluy creating instances of a primevue component

Posted: 28 Mar 2023, 16:31
by bahadirsofuoglu
Can you share a simple codesandbox example? An example we can talk about helps us.