- Vue.js 2 Web Development Projects
- Guillaume Chau
- 107字
- 2021-07-02 22:34:29
Renaming the note
This first toolbar feature is also the easiest. It only consists of a text input bound to the title property of the selected note with the v-model directive.
In the toolbar p element we just created, add this input element with the v-model directive and a placeholder to inform the user of its function:
<input v-model="selectedNote.title" placeholder="Note title" />
You should have a functional rename field above the text editor and see the note name change automatically in the note list as you type:

Since we set the deep option on the notes watcher, the note list will be saved whenever you change the name of the selected note.
推薦閱讀
- Learn TypeScript 3 by Building Web Applications
- Vue.js入門與商城開發(fā)實(shí)戰(zhàn)
- Dependency Injection in .NET Core 2.0
- Data Analysis with Stata
- bbPress Complete
- 前端HTML+CSS修煉之道(視頻同步+直播)
- Learning Laravel's Eloquent
- 青少年信息學(xué)競賽
- PLC應(yīng)用技術(shù)(三菱FX2N系列)
- Visual Basic程序設(shè)計(jì)習(xí)題與上機(jī)實(shí)踐
- 大學(xué)計(jì)算機(jī)基礎(chǔ)
- Building Dynamics CRM 2015 Dashboards with Power BI
- Python計(jì)算機(jī)視覺和自然語言處理
- 軟件工程與UML案例解析(第三版)
- ASP.NET本質(zhì)論