tnhnet priority asked 1 year ago

Expected behavior

bind treeview to v-model, update a variable with selected elements nameson @select event returns the items selected by name

Actual behavior

using v-model doesn't workthe @select event returns a list of html elements. my question is how do I get the list of selected names ?

Bartosz Cylwik staff answered 1 year ago

Hi! To get the list of selected names you can listen for select event on MDBTreeview component. When any of the treeview checkboxes are changed, select emit is sent.

You can see the code below to check how to use it.

    <MDBTreeview selectable @select="handleActive">

<script setup>
    const handleActive = (value) => {

Best Regards!

Please insert min. 20 characters.


Hire our experts to build a dedicated project. We'll analyze your business requirements, for free.



Specification of the issue

  • ForumUser: Priority
  • Premium support: Yes
  • Technology: MDB Vue
  • MDB Version: MDB5 3.0.0
  • Device: Any
  • Browser: Any
  • OS: Any
  • Provided sample code: No
  • Provided link: No