Articles
Latest
More
Newsletter Sponsorship Discord About
Sign up for our Newsletter
The video for this lesson is currently being updated, please read the transcript instead.
Build Your First Vue.js App > Lesson 21

Formatting price

In this video, we're going to make it so the prices that we display on the screen are correctly formatted with two digits after the decimal point, and with a dollar sign as a prefix.

The reason I'm specifying two digits after the decimal point, is that, currently, that's not enforced. If you add lots of items to the cart, you'll see we occassionally get these crazy long numbers. [add multiple items to the cart and see the total increase]


Back to course page

Click to load comments...

Articles
  • Latest
Newsletter
  • Join
  • Sponsorship
More
  • Discord
  • Vue.js jobs
  • About

Vue.js Developers © 2021. View our privacy policy .

  • RSS
  • |
  • Atom