In this tutorial, we will see how to check if an element contains a specific CSS class by entering the class name. <script setup> import { ref } from 'vue'…
Show the position of an element in Vue 3 Composition API | Example
In this tutorial, we'll learn how we can show the position of a element using the getBoundingClientRect() and display it on the page. Here's our main App.vue component: <script setup>…
How to render components dynamically in Vue 3 Composition API | Example
Being able to render components dynamically is one of the coolest features in Vue.js. What it means is that we can display a component only when we're able to match…
Best Vue.js UI libraries in 2023 – A comprehensive analysis
Vue is undeniably one of the best JavaScript frameworks to work with. Thanks to its simplicity, learning curve, and modern features, it throws most competitors out of the water in…
Password strength indicator for input field in Vue 3 Composition API | Example
In this tutorial, we'll have a look at how we can show a password strength indicator of varied colors (red, orange, green), based on the strength of the password. Earlier,…
How to display an array with comma separated list in Vue 3 Composition API?
Sometimes we may want to display items from an array separated by a comma. We know that displaying an array directly in the template will also include the square brackets.…
How to bind styles conditionally in Vue 3 Composition API | Example
Today we'll have a look at how we can bind CSS styles to elements conditionally (dynamically) in Vue 3. We'll take an example of an input field where we'd set…
Get day of the week from date in Vue 3 Composition API | Example
In this article, we will learn how to use the Vue 3 Composition API to get the day of the week from a date object. Code example <script setup> import…
How to use local storage in Vue 3 Composition API | Example
In this tutorial, we will create a simple Vue 3 application that utilizes the browser's local storage. We will start by importing the necessary modules from Vue, including the ref…