Movatterモバイル変換


[0]ホーム

URL:


Skip to content
DEV Community
Log in Create account

DEV Community

Joe Steinbring
Joe Steinbring

Posted on • Originally published atblog.jws.app on

     

Six ways to use data binding with Vue.js

This is going to be a pretty quick post. This week, I figured that we would look at computed properties and methods.

In the above example, we are takingDate.now() and outputting it to the screen four ways:

    • Directly as{{Date.now()}}
    • As the variabletime
    • As a computed value
    • As a method

What is the functional difference between them? In this case, very little. 🙂

So, what if we bind to our component’s data instead of toDate.now()?

So, now the value can actually update? 🙂

Please note, this is a republishing of apost that I wrote early last year, so please don't be too harsh.

Top comments(0)

Subscribe
pic
Create template

Templates let you quickly answer FAQs or store snippets for re-use.

Dismiss

Are you sure you want to hide this comment? It will become hidden in your post, but will still be visible via the comment'spermalink.

For further actions, you may consider blocking this person and/orreporting abuse

I write JavaScript by day and whatever interests me by night. I travel, have dogs, and enjoy playing with my ukulele.
  • Location
    Glendale, WI
  • Education
    MBA at Cardinal Stritch
  • Work
    Software Engineer/Developer IV at UW-Milwaukee
  • Joined

More fromJoe Steinbring

DEV Community

We're a place where coders share, stay up-to-date and grow their careers.

Log in Create account

[8]ページ先頭

©2009-2025 Movatter.jp