How to get an element group in vue

there is a group of li, under ul. I want to dynamically modify the width of ul according to the number of li. How to get all the li,ref in vue is to get the specified dom,. If it is native to get dom, I want to ask how to implement vue.

Mar.15,2021

<template>
  <ul ref="uldom">
    <li></li>
    <li></li>
    <li></li>
  </ul>
</template>
<script>
export default {
  mounted () {
    console.log(this.$refs.uldom.children)  // this.$refs.uldom uldom .children js 
  }
}
</script>

using ref is the best choice. It can effectively reduce the resource consumption caused by dom operations

MySQL Query : SELECT * FROM `codeshelper`.`v9_news` WHERE status=99 AND catid='6' ORDER BY rand() LIMIT 5
MySQL Error : Disk full (/tmp/#sql-temptable-64f5-1b3df60-2c3e3.MAI); waiting for someone to free some space... (errno: 28 "No space left on device")
MySQL Errno : 1021
Message : Disk full (/tmp/#sql-temptable-64f5-1b3df60-2c3e3.MAI); waiting for someone to free some space... (errno: 28 "No space left on device")
Need Help?