No exciting personal updates this week. However, I migrated my Nuxt Starter Kit to Nuxt UI v4 (alpha)! You can now use it without a Nuxt UI Pro license and get access to all Nuxt UI Pro components for free.
💡 Vue Tip: Getting the Previous Value of a Computed Property
Since Vue 3.4+ you can get the the previous value returned by the computed property accessing the first argument of the getter:
1<script setup>2import { ref, computed } from 'vue'34const count = ref(2)56// This computed will return the value of count when it's less or equal to 3.7// When count is >=4, the last value that fulfilled our condition will be returned8// instead until count is less or equal to 39const alwaysSmall = computed((previous) => {10 if (count.value <= 3) {11 return count.value12 }1314 return previous15})16</script>
👉🏻 The TC39 committee has advanced nine proposals, including the newly standardized explicit resource management feature using the using keyword for automatic cleanup, and Array.fromAsync for handling async iterables.
Weekly Vue News #194 Reactive Time Ago View online Hi 👋 I'm on vacation this week, so no special news from my side — just some fresh Vue & Nuxt content for you! Enjoy this issue and have a lovely week ☀️ Vue 📕 Optimizing heavy operations in Vue with Web Worke...
Weekly Vue News #205 Weekly Vue News #205 - Vue Language Tools 3.0, useSlots, Nuxt Tips & More! View online Hi 👋 I'm back from my vacation and ready to share the latest Vue & Nuxt news with you! Enjoy this issue and have a lovely week ☀️ Vue 📕 What is useSlots in Vue? ...
Read this on my blog Hey all! Tomorrow I'm launching Composable Design Patterns — a collection of 15 patterns on how to use the composition API better. I've been working on this for a while (it's been in my head for years), and I'm excited to share it with you! You'll be getting a special launch discount, so make sure to pay attention to your email inbox tomorrow. Other than that, I've got a new podcast episode for you, and some links to check out, as well as some tips. Enjoy your week! — Michael ...
评论
发表评论