Skip to main content

Working with Form Elements

  • Chapter
  • First Online:
Pro Vue.js 2
  • 2047 Accesses

Abstract

In this chapter, I describe v-model, which is the built-in directive used for HTML form elements. The v-model directive creates a two-way data binding between a form element and a data value and ensures that the application remains consistent, regardless of how the data is changed. I also show you how to combine the v-model directive with some of the built-in directives described in earlier chapters to validate the data entered into a form by the user. Table 15-1 puts the v-model directive in context.

This is a preview of subscription content, log in via an institution to check access.

Access this chapter

Chapter
USD 29.95
Price excludes VAT (USA)
  • Available as PDF
  • Read on any device
  • Instant download
  • Own it forever
eBook
USD 54.99
Price excludes VAT (USA)
  • Available as EPUB and PDF
  • Read on any device
  • Instant download
  • Own it forever
Softcover Book
USD 69.99
Price excludes VAT (USA)
  • Compact, lightweight edition
  • Dispatched in 3 to 5 business days
  • Free shipping worldwide - see info

Tax calculation will be finalised at checkout

Purchases are for personal use only

Institutional subscriptions

Author information

Authors and Affiliations

Authors

Rights and permissions

Reprints and permissions

Copyright information

© 2018 Adam Freeman

About this chapter

Check for updates. Verify currency and authenticity via CrossMark

Cite this chapter

Freeman, A. (2018). Working with Form Elements. In: Pro Vue.js 2. Apress, Berkeley, CA. https://doi.org/10.1007/978-1-4842-3805-9_15

Download citation

Publish with us

Policies and ethics