I am new to Vue.js and I am looking at someone's code. I noticed they are using the @ symbol. What does this do and what is it used for?
export default {
methods: {
handleCreate() {
console.log('Child has been created.');
}
}
};
<template>
<ChildComponent @created="handleCreate" />
</template>
// ChildComponent
export default {
created() {
this.$emit('created');
}
}
In your case, the @ symbol, symbol is shorthand for v-on . It can also be used when importing to resolve things.
Vuex is a state management pattern for vue. js. $t is the injected method from vue. js or Vue.
Vue uses an HTML-based template syntax that allows you to declaratively bind the rendered DOM to the underlying component instance's data. All Vue templates are syntactically valid HTML that can be parsed by spec-compliant browsers and HTML parsers.
In your case, the @ symbol, symbol is shorthand for v-on
.
It can also be used when importing to resolve things.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With