Meet the vue has been an error assigning to rvalue solution, always thought that is a question of js code, look behind for a long time, were found in the HTML template v – model binding attribute is not defined in the data property. As follows:
<template> <div class="search-box"> <div class="wrap"> <input v-model="searchText" class="search-input" type="text"> <div class="search-botton"></div> </div> </div> </template> <script> export default { name: 'searchBox', data() { return { }; } }; </script>
After modification:
<template> <div class="search-box"> <div class="wrap"> <input v-model="searchText" class="search-input" type="text"> <div class="search-botton"></div> </div> </div> </template> <script> export default { name: 'searchBox', data() { return { searchText: '' }; } }; </script>
Solve problems.
The main thing to notice here is that in js code searchText is named in hump format, as well as in V-Model. Props being used in the template is not the same as wanting to convert the hump in JS to a short line. This is because the attributes in HTML are case-insensitive. However, v-Model is enclosed in quotation marks, so it is case sensitive, while short lines make an error. Detailed reference: https://blog.csdn.net/yuetingzhuying/article/details/49820689
Read More:
- Vue Error-Error message: Syntax Error: Assigning to rvalue.
- Nohup command in Linux: nohup: assigning input and attaching output to‘ nohup.out ’
- Automatically assigning platform `iOS` with version `8.0` on target `Runner`
- How to solve problems like curl: (7) failed to connect to raw.githubusercontent.com Port 443: problem with connection used
- How to restrict input field to only input pure numbers in HTML
- Tensorflow: How to use expand_Dim() to add dimensions
- Failed to connect to Mir:Failed to connect to server socket:No such file or directory
- RuntimeError: Unable to find a valid cuDNN algorithm to run convolution
- Solution to the problem of vs2017 error report unable to open source file
- How to Fix failed to Connect to MySQL at localhost:3306 with user root
- express nodejs Failed to lookup view error in views directory (How to Fix)
- Kibana was degraded from 7.0 to 6.8 and started to report an error
- VUEJS Failed to execute ‘removeChild’ on ‘Node’: The node to be removed is not a child of
- Uncaught TypeError: Failed to execute ‘appendChild’ on ‘Node’: parameter 1 is not of type ‘Node How to Fix
- Using AspectJ to transfer the data written to FTP service to MySQL database
- Vue element El input search to achieve anti shake @ input event requests frequently
- Solution to Spacy’s failure to load (‘de ‘) or (‘en’)
- JDBC connect to Sql Server to connect to the database–The TCP/IP connection to the host localhost, port 1433 has failed
- [Linux] curl: (7) failed to connect to 127.0.0.1 port 1086: connection reused solution
- How to convert audio to subtitle (text) with Python?