
Vue Components
Component lifecycle, props, events, slots, scoped styles, component communication, dynamic components
1What is a Vue component?
What is a Vue component?
āļāļģāļāļāļ
A Vue component is a reusable Vue instance with a name. It encapsulates HTML, CSS and JavaScript into an independent logical unit. Components allow dividing the user interface into reusable and maintainable pieces. Each component has its own template, logic and styles, facilitating code organization and reusability.
2How to declare props in a Vue 3 component with script setup?
How to declare props in a Vue 3 component with script setup?
āļāļģāļāļāļ
In Vue 3 with script setup, defineProps() is a compiler macro that allows declaring props without explicit import. This macro automatically generates the necessary code and exposes props to the template. It supports TypeScript and JavaScript type validation, making the code more concise and type-safe than the Options API approach.
3What is the function of the onMounted() hook in a component lifecycle?
What is the function of the onMounted() hook in a component lifecycle?
āļāļģāļāļāļ
The onMounted() hook executes after the component has been mounted to the DOM. This is the ideal moment to perform operations that require DOM access, like initializing third-party libraries, fetching data via API, or directly manipulating DOM elements. At this stage, the template is rendered and refs are accessible.
How does a child component emit an event to its parent component?
What are slots used for in a Vue component?
+17 āļāļģāļāļēāļĄāļŠāļąāļĄāļ āļēāļĐāļāđ
āļŦāļąāļ§āļāđāļāļŠāļąāļĄāļ āļēāļĐāļāđ Vue.js / Nuxt.js āļāļ·āđāļāđ
JavaScript Fundamentals
Modern JavaScript (ES6+)
Vue Basics
Vue Router
Pinia State Management
Vuex (Legacy)
Composition API
Vue Reactivity
Nuxt Fundamentals
Nuxt Data Fetching
Nuxt SSR & SSG
Nuxt Server Routes
Nuxt Modules
Vue Composables
Vue Forms & Validation
Nuxt State Management
Vue Testing
Nuxt Deployment & CI/CD
Vue Performance
Vue Advanced Patterns
TypeScript with Vue
Nuxt Authentication
SEO with Nuxt
Nuxt Internationalization
Vue Architecture
Nuxt Security
Vue Ecosystem
Migration Vue 2â3 & Nuxt 2â3
āđāļāļĩāđāļĒāļ§āļāļēāļ Vue.js / Nuxt.js āļŠāļģāļŦāļĢāļąāļāļāļēāļĢāļŠāļąāļĄāļ āļēāļĐāļāđāļāļĢāļąāđāļāļāļąāļāđāļ
āđāļāđāļēāļāļķāļāļāļģāļāļēāļĄāļāļąāđāļāļŦāļĄāļ flashcards āđāļāļāļāļāļŠāļāļāđāļāļāļāļīāļ āđāļāļāļāļķāļāļŦāļąāļ code review āđāļĨāļ°āļāļąāļ§āļāļģāļĨāļāļāļŠāļąāļĄāļ āļēāļĐāļāđ
āđāļĢāļīāđāļĄāđāļāđāļāļĢāļĩ