Vue 3 & Composition API - Full Project

Sdílet
Vložit
  • čas přidán 18. 05. 2024
  • Build an expense tracker application from scratch using Vue.js 3 and the composition API with the latest syntax from version 3.2.
    Final Code:
    github.com/bradtraversy/vue-e...
    Vanilla JS Project Repo:
    github.com/bradtraversy/vanil...
    Blog Post:
    www.traversymedia.com/blog/vu...
    Check Out My Courses:
    traversymedia.com
    Timestamps:
    0:00 - Intro & Demo
    3:21 - Vue.js Setup
    4:57 - File Structure
    7:44 - Boilerplate Clean Up
    9:06 - Create Component Files & Templates
    12:30 - Create and import Components
    18:50 - TransactionList Display
    28:37 - Transactions in Global State
    30:12 - Pass & Recieve Props (defineProps)
    32:30 - Balance Component & computed()
    37:21 - Income & Expenses Component
    42:34 - AddTransaction Form Component
    44:58 - Binding Form Inputs
    46:41 - Validation & Toasts
    52:05 - Emit Custom Events (defineEmits)
    54:45 - Add Transaction to State
    59:30 - Deleting Transactions
    1:03:30 - Fetch From Local Storage & OnMounted()
    1:06:09 - Save to Local Storage
  • Věda a technologie

Komentáře • 182

  • @prasannabakare0456
    @prasannabakare0456 Před 6 měsíci +50

    Vue JS soo easy to implement especially in composition API. I prefer it more over react.

    • @TraversyMedia
      @TraversyMedia  Před 6 měsíci +8

      It really is super straightforward. I love React, but there are a lot of quirks to get used to.

    • @neneodonkor
      @neneodonkor Před 2 měsíci

      Me too. 👍🏾👍🏾👍🏾

  • @Zetlify_Official
    @Zetlify_Official Před 6 měsíci +64

    In the world of popularity, I decided to stick with VueJS , Thank you so much Mr. Brad for another inspirational video.

    • @wovasteengova
      @wovasteengova Před 5 měsíci +3

      ya me too. I am going to stick with them.

    • @shawnshaw9859
      @shawnshaw9859 Před měsícem

      @@wovasteengova me too, the only true community based frontend framework while react lost it way and svelte got bought up

  • @mouradeljayi584
    @mouradeljayi584 Před 6 měsíci +44

    Glad you are still uploading Vue JS content.. Thank's Brad !

    • @TraversyMedia
      @TraversyMedia  Před 6 měsíci +34

      No problem. Thanks for watching! I will be doing a Vue course at some point next year. Which also means more Vue CZcams content as well.

    • @rajeshbudhathoki7888
      @rajeshbudhathoki7888 Před 6 měsíci +1

      WOW! 🤩@@TraversyMedia

    • @mahmoodbina2193
      @mahmoodbina2193 Před 6 měsíci +1

      @@TraversyMedia pleaseeeee do it !!!! Even in your website , we will buy and support

  • @namaefumei
    @namaefumei Před 6 měsíci +23

    My god I love Vue. I had to use react for a company project for a year and every second I thought there is an easier way in Vue

    • @caaltz
      @caaltz Před 3 měsíci +4

      I tried to learn react 4 times, every time I get bored to death and feel no joy at all, I use at my work sometimes to adjust some projects from the guys that leave, my boss just decided to use Vue with our Laravel projects and I'm really happy about it!

  • @xbmcme9768
    @xbmcme9768 Před 3 měsíci +1

    I've been watching your videos for a while now. It was your videos that got me started on programming. 5 years laters, you're still cranking out banger content. Thanks!

  • @mounir101
    @mounir101 Před 6 měsíci +1

    Glad to see you again in this new Vuejs tut. Pretty awesome, and thanks so much Mr. Brad

  • @beakdan
    @beakdan Před 6 měsíci

    Thank you! I started to learn vue recently after more than 15 years of not working with web technologies and was confused about a lot of things. I followed religiously the instructions of your other vue video but I was still confused and learning the "setup" style. This video answered my questions, now I clearly understand the purpose. Again, thank you!

  • @junior.santana
    @junior.santana Před 6 měsíci +4

    Great tutorial!
    I'm new to Vue and even though I had already seen all the stuff you showed, it was really good to understand better the composition API.
    Also, it's always good to see tutorials with a nice UI and covering all functionalities like that

  • @febryanakhdani4244
    @febryanakhdani4244 Před 5 měsíci +1

    just trying this vue tutorial 3 days ago and finally I can understand about the props and emits concept. such a great and amazing video. I hope you can continue the tutorial of vue 3. thanks you so much

  • @mariusvranceanu8595
    @mariusvranceanu8595 Před 6 měsíci +4

    I finished your JS from scratch course a few weeks ago and started doing projects, got the hang of it and tried React . Wasn't my cup of tea, especially having used SvelteKit a bit, but Vue, I like their background story a lot and I picked it up yesterday and It just happened that you uploaded a Vue 3 video. Awesome! Thank you!

  • @paulthomas1052
    @paulthomas1052 Před 6 měsíci

    Great demo as always - well paced and full of relevant real-word content. Thanks !

  • @matthewcorbett8637
    @matthewcorbett8637 Před 6 měsíci

    Ive been building a passion project in Vue the last year! Cant wait to use this toast lib to add a little pazaz to my UI 😊 Thanks Brad!!

  • @modris2980
    @modris2980 Před 5 měsíci

    Thank you so much for creating this tutorial. A total beginner here and it's perfect.

  • @Patrick-jn9je
    @Patrick-jn9je Před 6 měsíci

    Your tutorials are really easy to digest. That 1 hour just passed by so quickly.

  • @allprowebdesigns917
    @allprowebdesigns917 Před měsícem

    Good to see you back with a Vue JS tutorial and the composition API for Vue's reactivity components.

  • @sogbeydaniel8074
    @sogbeydaniel8074 Před 6 měsíci +6

    ❤. Just started learning Vue about a week ago

    • @Coderdawg
      @Coderdawg Před 6 měsíci

      How’s your learning going so far?

    • @sandeshshrangare
      @sandeshshrangare Před 6 měsíci

      I'm also learning vue js .. is it worth it. Cus. Of im scare about all these things

  • @asadmalik5075
    @asadmalik5075 Před 6 měsíci +1

    Wow so much straight forward since I am a React Developer I am impressed how the Vue works

  • @STR2060
    @STR2060 Před 2 měsíci +3

    Your explanation of these Vue's basic concepts is just so straightforward. Unlike some guys who will spend 100,000 years to describe it's features whatever before show me the practical usage.

  • @cecitorresmx
    @cecitorresmx Před 6 měsíci +10

    Thank you Brad, thanks to you I got my first job as frontend developer 5 years ago, Your course for Vue.js helped me a lot with the interview and my first months there. Now I'm looking for a new position and I was looking for some recap in Vue 3 for my next job interviews and I found your video! I'm sure I'm going to repeat the same good luck :)

  • @cheesypizzajokes
    @cheesypizzajokes Před 6 měsíci

    Coincidental that I decided to learn Vuejs properly today with your 2021 Vue js crash course, got to where you said you werent covering composition api, googled to see if you ended up making that separate vid, and whaddya know, published "3 days ago"
    Thanks as always, Brad

  • @_moxy9905
    @_moxy9905 Před 6 měsíci +8

    Yeaaaaaaaa, best framework ever 🎉🎉🎉

  • @SamuelCoupland
    @SamuelCoupland Před 2 měsíci

    Thank you for this! Really helpful for a crash course before an interview where they use Vue. Coming from React it was just a perfect overview, and plenty of times I went off to the docs and learnt something new about Vue. Thank you again Brad!

  • @amidipu
    @amidipu Před 5 měsíci

    Great tutorial. specific and no boiler plate talks as always from you, like it 🙂

  • @user-fj7df3ng7z
    @user-fj7df3ng7z Před 4 měsíci +1

    Excellent course, Brad! I just completed a Vue basics course on another channel and was going to start writing my own code right away but decided a little more practice would help, as would hearing things explained by a different person. I'm glad I went that way! I now understand several things better. As a huge bonus, you finally cleared up the difference between the options API, the composition API and the composition API with the tag, which had REALLY been confusing me in various examples I had been examining. That alone is going to make my future coding projects easier! I've done several of your courses now and they are consistently excellent so thank you VERY MUCH for doing what you do so well!

  • @derricknjoroge2494
    @derricknjoroge2494 Před 6 měsíci +1

    Looking forward to learning here

  • @Viralplace
    @Viralplace Před 6 měsíci

    Wooow thanks Brad from Italy! I love vue, hope to see more video about that and vite + pinia

  • @caaltz
    @caaltz Před 3 měsíci

    Thanks Brad, your content is excellent. Love your teaching style

  • @JuanPalominoMusic
    @JuanPalominoMusic Před měsícem

    Thanks for this tutorial, helped me transitioning from Vue 2 to Vue 3.

  • @stephenng4036
    @stephenng4036 Před 2 měsíci +1

    I have no choice but give a big like to this wonderful tutorial.

  • @UberDurable
    @UberDurable Před 6 měsíci

    Excellent as always, much appreciated.

  • @andresgarciaalves
    @andresgarciaalves Před 6 měsíci

    Thank you Brad, awesome content 😊

  • @michaels.5001
    @michaels.5001 Před měsícem

    Absolutely great tutorial, mega well explained.

  • @greatssmartnetsystems
    @greatssmartnetsystems Před 26 dny

    Just on point. 🎉 thank you

  • @fvgoya
    @fvgoya Před 6 měsíci

    Great content as always Brad. Will be also awesome see some videos about Nuxt. Thanks Brad!!

  • @user-st3ek4lq2l
    @user-st3ek4lq2l Před 6 měsíci

    Tutorial is awsome, just what i need!

  • @alques-dias
    @alques-dias Před 4 měsíci +1

    Awesome job, please make more content with Composition API

  • @MuratcanBerber
    @MuratcanBerber Před 5 měsíci +17

    I watched maybe a dozen different Vue 3 Composition API tutorials, and this is the one that made me really understand these concepts. Props, emits, life cycle functions... it's more than just a crash course. As always, Brad, you made my day and really showed how good your tutorials are. Your ability to teach is exceptional. The world is a better place because of you. Thank you for the video. I hope you will continue to enjoy creating content to make software really fun and understandable. Thank you again.

    • @Aeric80
      @Aeric80 Před 5 měsíci

      I strongly agree with you. Brad explains the concepts and practical in a very straight forward and concise way where I find other videos are long winded and confusing.

  • @munraitoo13
    @munraitoo13 Před měsícem

    Thank you for your knowledge!

  • @wb2c0
    @wb2c0 Před 5 měsíci

    hands down the best teacher

  • @je-suis-alin
    @je-suis-alin Před 4 měsíci

    I'm here just to say "Hi!" to Brad! You are awesome, as always!

  • @isaacqadri
    @isaacqadri Před 6 měsíci +4

    Vue3+composition api❤❤❤

  • @kingvas7638
    @kingvas7638 Před 6 měsíci +1

    Best frontend framework!! Vue❤

  • @olalekanidowu7078
    @olalekanidowu7078 Před 2 měsíci

    This is very great, thanks Brad

  • @selviaantoine5701
    @selviaantoine5701 Před 5 měsíci

    Thank you so much Brad.

  • @salmanahmedkhan3979
    @salmanahmedkhan3979 Před 3 měsíci

    great video. now i can do the tasks of my job.

  • @jarabialex
    @jarabialex Před 6 měsíci

    Awoohoo! Looking forward to coding along

  • @GilAguilar
    @GilAguilar Před 6 měsíci +4

    Nice I know this is going to be great!
    Once that music starts and your voice is heard.
    My laptop says , let’s do this 🤟💙💪🏽☕️

  • @jonl316
    @jonl316 Před 6 měsíci +1

    Love this content. Vue is the way to go.

  • @codedjango
    @codedjango Před 6 měsíci

    Thank you so much for this Vue tutorial

  • @dennismuthomi712
    @dennismuthomi712 Před 6 měsíci

    Thank you Brad!

  • @doyouknowthishacks
    @doyouknowthishacks Před 5 měsíci

    You Explaination is awsome .... dear.... and also conent project is excellent.... keep it up dear

  • @gogoikabir
    @gogoikabir Před 6 měsíci

    Thank you for the video ❤

  • @yugeyuge8008
    @yugeyuge8008 Před 3 měsíci +1

    Thanks for the good tutorial.

  • @m3-dev
    @m3-dev Před 2 měsíci

    Thanks!!! great explaination. now to try it on my own 😜

  • @VitaliySunny
    @VitaliySunny Před 6 měsíci

    Thanks, very cool project.

  • @iUmerFarooq
    @iUmerFarooq Před 6 měsíci +6

    Love to see Vue content on your channel.
    Want to se Nuxt 3 also. Make some fullstack projects in Nuxt 3.
    Thank you ;)

  • @geek_muslim
    @geek_muslim Před 2 měsíci

    Thanks bro this was awesome

  • @Cire-my6ur
    @Cire-my6ur Před měsícem

    You have always been really good at explaining how things work. Just explaining simply, how the il hover and transition works was extremely helpful. I hate css; always confuses me.
    Good video and perfect for someone that wants to get a better idea of how Vue works if you’re trying to incorporate it into your project.

  • @glatocha
    @glatocha Před 6 měsíci

    ha, love it, Exactly what my next APP will be. But on top of what you have I will have supabase behind the data and quasar to help out with workflow and UI components

  • @peterpen983
    @peterpen983 Před 6 měsíci

    Good job my bro!

  • @raksmey9780
    @raksmey9780 Před 6 měsíci

    superb turtorial

  • @chandrachurmukherjeejucse5816

    Goated Lecture fr.

  • @DaniilTheCoder
    @DaniilTheCoder Před 22 dny

    Огромное спасибо за написание небольшого приложения на Вью! Как раз после изучения документации хочется закреплять знания, что-то подглядывать у более опытных разработчиков 🤝

  • @MacKoslowski
    @MacKoslowski Před 6 měsíci +1

    Chose Vue for work projects and haven't regretted it. Give it a shot!

    • @neneodonkor
      @neneodonkor Před 3 měsíci

      I presume you work as a freelancer.

  • @ilyasbenihia869
    @ilyasbenihia869 Před 6 měsíci

    I love Vue and i love you content

  • @akashshetty6422
    @akashshetty6422 Před 2 měsíci

    thanks for the video

  • @user-ii6rb6nw8c
    @user-ii6rb6nw8c Před 6 měsíci

    thank you so much

  • @chungtunguyen6135
    @chungtunguyen6135 Před 5 měsíci

    thanks for this tutorial! it's very helpfull!

  • @ionelgis
    @ionelgis Před 6 měsíci

    Love Vue with composition api. It's also very similar to Svelte

  • @user-ye1xz3xx2u
    @user-ye1xz3xx2u Před 6 měsíci

    thank you so much!

  • @atlantisuds6625
    @atlantisuds6625 Před 5 měsíci +1

    Thank you for your video. I'm new in Vue, and this tutorial taught me a lot of basics. I hope you can make better and better videos!

  • @machelealhassan1496
    @machelealhassan1496 Před 4 měsíci

    Superb!

  • @WESHAREknowledge
    @WESHAREknowledge Před 3 měsíci

    thank you

  • @user-vn2ot8pd9r
    @user-vn2ot8pd9r Před 6 měsíci

    You are awesome... Like always ❤👍

  • @user-bh7pe9ti7f
    @user-bh7pe9ti7f Před 5 měsíci

    Thanks you so much

  • @adriancastillo3370
    @adriancastillo3370 Před 6 měsíci

    THANK YOU

  • @basicsprogrammingandelectr3043

    it's really good, helpfull video thanks vary much

  • @claudiocl8937
    @claudiocl8937 Před 5 měsíci

    Nice tutorial

  • @kurshadqaya1684
    @kurshadqaya1684 Před 6 měsíci +2

    Then only channel I just press like no matter I watch or not.

  • @addoconstant
    @addoconstant Před 4 měsíci

    Vue is the best js frontend framework. the implementation is seamless

  • @IT_with_Glitch
    @IT_with_Glitch Před 6 měsíci

    Brad loves from costa rica mate, hopefully one day i will appear on one of your videos.

  • @gadgetkh9408
    @gadgetkh9408 Před 6 měsíci +2

    Great content. Thank you! Can you please also create video of Vue3+ionic+capacitor?

  • @josoataryll4077
    @josoataryll4077 Před 2 měsíci

    Thanks😊

  • @elenacoman33
    @elenacoman33 Před 9 dny

    Great tutorial, I really enjoy it.
    Just in case it's helpful to anyone, you can enable decimals with input of number types, by adding step attribute. For instance:
    Thank you very much for the tutorial! 🌞

    • @zlotnytskiy
      @zlotnytskiy Před 7 dny +1

      also add number modifier, v-model.number="amount", otherwise, the v-model will return a string

  • @kendouciabdelaliilyas
    @kendouciabdelaliilyas Před 6 měsíci

    Thanks Brad. I hope some contents for Nuxt 3

  • @nadetdevfullstack7041
    @nadetdevfullstack7041 Před 6 měsíci

    Excellent

  • @johnacsyen
    @johnacsyen Před 2 měsíci

    Great tutorial. Learning Vue for first time. @1:05:05, Coming from React, Vue seems easier

  • @user-du8lw4ur6v
    @user-du8lw4ur6v Před 2 měsíci

    Thanks alot

  • @allenboniface8010
    @allenboniface8010 Před 6 měsíci

    Watching from Tanzania

  • @user-su4rd3ml8b
    @user-su4rd3ml8b Před 6 měsíci

    brad is like that awesome older brother figure we never had, love you man thanks a lot for all these years

  • @zuberab5405
    @zuberab5405 Před 6 měsíci

    welcome back

  • @Bella_Will
    @Bella_Will Před 6 měsíci

    Great!
    Please can you create a content on API endpoint documentations.

  • @user-fj7df3ng7z
    @user-fj7df3ng7z Před 4 měsíci

    Just an idea, Brad, but I had an idea that might appeal to you: with the finished program from this video as a starting point, revise it to incorporate Pinia for all state management and local storage. I'm thinking of making that change in my own code....

  • @0Xmo
    @0Xmo Před 3 měsíci

    u are the beeeeeeeest ♥

  • @teckyify
    @teckyify Před 6 měsíci +7

    I can remember using the compositional api 1 or 2 years ago without the script setup tag. However, besides the convenience of not having a components object it looks actually more unorganized than having the traditional structured default object.

    • @TraversyMedia
      @TraversyMedia  Před 6 měsíci +10

      I can see your point. I was a big fan of the options API and was turned off from the whole setup() function. I do like the new syntax though. I'm a big fan of the more vanilla-like just create variables and functions and they just work. It's really just preference. I'm glad the options API is still an option though. No pun intended lol

  • @dgloria
    @dgloria Před 5 měsíci

    Fab! Will do this asap. Does it use pinia? Does it use components from a single external source? I was never able to understand how to make buttons, modals etc as reusable components in Vue3. :)

  • @da_stoaz
    @da_stoaz Před 4 měsíci

    Really appreciate this tutorial. But which VSCode extensions do you use?

  • @mylesdavies9476
    @mylesdavies9476 Před 6 měsíci +1

    ❤ Vue 😊

  • @beticohernandez9536
    @beticohernandez9536 Před 5 měsíci +1

    Que bien

  • @Aeric80
    @Aeric80 Před 5 měsíci

    Hi Brad, I am a bit confuse when writing defineProps, there is no variable call transactions but you can reference the transactions prop in the component.
    edit: sorry, I rewatch and saw it. It is one level up from the type and required.