The vue-prop parent component transmits values to child components, and the vue-prop component transmits values.
Vue-prop is used when the parent component transmits data to the child compone
/dialog-icon/index. vue File
Component/dialog/index. vue File
Component/mask/index. vue File
Vuex
The status is centrally stored in the store for management, and the status is changed through mutations. The component calls muta
Vue. js uses vue-router to redirect to a page. vue. jsvue-router
Preface
When using Vue. js for a project, a page consists of multiple components. Therefore, the traditional href is not suitable when you jump to the page. Therefor
Communication between Vue. js components and vue. js Components
Preface
Because Vue. js is very interested, and the technology stack that we usually work on is also Vue.
Vue. js: custom components and vue. js
OverviewWe know that a Vue instance can be bound to a view through el, that is, it acts as a ViewModel. In fact, a Vue instance can not only act as a ViewModel, in addition, you can see a
, when the final development completed on-line when the production version is introduced, the development version is not compressed, and there are manyAnd the production version is all erased.Providing a scaffold (command-line tool) in Vue can help us quickly build a webpack-based development environment ...Example of VueEach application has a root instance, and in the root instance we implement a large application through the nesting of componentsTha
Vuejs customizes a . vue file, which can be used to write HTML, CSS, JS into a file, thus enabling the encapsulation of a component, a . vue file is a separate component. Because the. vue file is custom, the browser does not know
, and js Code of the component with one click to quickly apply the Code to the project, so that the front-end development cost of the component is close to zero. The platform must implement the following functions:
* The management component supports classification, search, and sorting.
* Displays components and supp
return isUpper ? val.toUpperCase() : val.toLowerCase();6 }7 }
For the convenience of viewing the effect, we modify the text box code of v-model = "msg" above as follows:
1
We added a {msg | toUpper (true)} Writing Method to the text box. The toUpper we just defined is the method of the filter, A parameter true is passed, and you can see the following:
By comparing the filters with different parameters, we can see the effect of our filters in this instance.
A Vue-loaderWe don't care about scaffolding, just talk about Vue-loader, simply say that you can package the. vue file for component development, that is, a. vue file is a component that only needs to be introduced in development.
Vue jsx User Guide and vue. js method using jsx syntax, vue. jsjsx
The vue jsx syntax is different from the react jsx syntax, which is recorded here.
Let component = null // if statement if (true) {
Transition and animation are required for Vue. js every day, and transition animation for vue. js
With the transition system of Vue. js, You can automatically apply the transition effect when an element is inserted or removed from
Client
I will use Vue CLI to generate the basic vue. js App. If you have not installed it, run:
$ npm install -g vue-cli
The client and backend code are split into different folders. Initialize the front-end running tracking:
$ mkdir flaskvue$ cd flaskvue$ vue init webpack
Vue component (component) Example of exquisite calendar method implementation, vuecomponent
Component is one of the most powerful functions of Vue. Components can expand HTML elements, encapsulate reusable code, and abstract some components based on project requirements. Eac
following command in git bash:
vue init webpack-simple my-webpack-simple-demo
webpack-simpleIs the name of the project template,my-webpack-simple-demoIs the name of the project you want to generate.
The directory generates a folder my-webpack-simple-demo.
2. Project Structure Description
Open the my-webpack-simple-demo folder and see the following directory structure:
The file tree structure is as follows:
─ ──. Babelrc // babelconfiguration file z
When we usually use the Vue component, we often need to pass some of the parent component's data to the child components, this time, we usually have a lot of methods, here are mainly divided into two situations:
The first type : static data passing: passing a stringThe second type : Dynamic Data Passing: Binding a string to pass through, an array, or an object passing past
Here's a look at Dynamic data bind
Let's talk about the transition effect of Vue. js and the transition effect of Vue. js.
With the transition system of Vue. js, you can easily add transition animation effects to the process of DOM node insertion/removal.
The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion;
products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the
content of the page makes you feel confusing, please write us an email, we will handle the problem
within 5 days after receiving your email.
If you find any instances of plagiarism from the community, please send an email to:
info-contact@alibabacloud.com
and provide relevant evidence. A staff member will contact you within 5 working days.