Skip to content
tezvyn:

Vue, Angular & Svelte

Vue 3, Nuxt, Angular, Svelte, SvelteKit

307 bites

Test yourself: Top 30 Vue, Angular & Svelte interview questionsMultiple choice, with the correct answer and why it is correct on every question. Free, no sign-in.

Everything in Vue, Angular & Svelte, page 4

easy2 min read

Vue computed vs method: performance difference and when to choose each?

This tests Vue reactivity caching. Answer: computed caches and reruns only when reactive deps change, while methods run each render. Choose computed for derived data; methods for events/args. Red flag: saying computed is always faster or passing arguments.

Explain Svelte Action update and provide a reactive CSS example
advanced2 min read

Explain Svelte Action update and provide a reactive CSS example

Tests Svelte actions beyond initial mount. Strong answers explain update re-runs when parameters change, give a CSS custom properties example, and contrast with destroy. Red flag: suggesting the action re-runs from scratch or using reactive statements.

advanced2 min read

When would you provide an Angular service at the component level?

Tests Angular DI scoping beyond singletons. A strong answer picks stateful reusable widgets, explains providers create one instance per subtree, and notes cleanup on destroy. Red flag: claiming this is for performance without mentioning state isolation.

advanced2 min read

How would you design useCounter to support shared or independent state?

Tests your grasp of scope in Vue composables. Great answers contrast module-level refs for global singleton state against function-level refs for per-instance isolation, and explain tradeoffs.

intermediate2 min read

Architect reusable form validation in Vue vs Angular

Tests how you encapsulate reactive state across frameworks. Contrast Vue's useForm composable returning refs and lifecycle hooks. Contrast Angular's service exposing a FormGroup via RxJS.

How would you create a parameterized Svelte tooltip Action?
intermediate2 min read

How would you create a parameterized Svelte tooltip Action?

It tests your grasp of the Svelte Action lifecycle for reactive parameters. Answer: action takes node and parameter, returns update and destroy, bound as use:tooltip={text}. Using component events instead of the Action API, or omitting update, is a red flag.

intermediate2 min read

Vue 3 Composables vs Vue 2 Mixins: differences and problems solved

Tests why Vue replaced mixins with composables for stateful logic reuse. Answers cite property collisions, unclear origin, inflexible config, and weak type inference.

intermediate2 min read

Would you use a Service or a custom Pipe for currency formatting?

Choose Pipe for declarative syntax; implement PipeTransform with transform(value, ...args); use Intl.NumberFormat; register standalone.

What is a Svelte Action? Write a simple logging action.
easy2 min read

What is a Svelte Action? Write a simple logging action.

Define a function receiving the node, log a message, and optionally return destroy.

How to create a singleton Angular auth service
easy2 min read

How to create a singleton Angular auth service

Tests Angular dependency injection and singleton scope. Strong answer: use the Injectable decorator with providedIn set to root for an application-wide singleton, then inject it into components.

easy2 min read

How do you implement a data-fetching Composable in Vue 3?

Write useFetch accepting a URL, exposing data, loading, and error refs, then return them.

advanced2 min read

How do you manage router scroll behavior and history position restoration?

Use scrollBehavior to return savedPosition on popstate and top: 0 on new navigations; handle hash anchors and async delays.

Contrast SvelteKit file-system routing with Vue/Angular router configs
advanced2 min read

Contrast SvelteKit file-system routing with Vue/Angular router configs

Contrast SvelteKit directory routes with Vue/Angular config routers; filesystem routing removes boilerplate but couples URLs to folders and limits dynamic registration.

What is the purpose of an Angular Resolve guard vs ngOnInit?
advanced2 min read

What is the purpose of an Angular Resolve guard vs ngOnInit?

Tests routing lifecycle timing and UX state management. Strong answers: Resolve blocks activation until data returns; ngOnInit renders first then fetches, causing flicker.

intermediate2 min read

What are nested routes and why are they useful?

Nested routes render children inside a parent's router-view, preserving shared layouts while URL segments swap nested content.

How do you configure a route for lazy loading?
intermediate2 min read

How do you configure a route for lazy loading?

Tests route-level code splitting and initial bundle control. Outline: dynamic imports in route config, on-demand chunk fetching, and measurable load-time wins versus eager loading. Red flag: treating lazy loading as just images or components, not route code.

intermediate2 min read

Explain navigation guards and provide an auth use case

Guards are global, per-route, or in-component hooks; returning false cancels, a route object redirects; use auth on /dashboard.

intermediate2 min read

How do you create a dynamic route and access the id parameter?

This tests Vue Router dynamic segment syntax and param access. Define the path with a colon like /products/:id, then read via useRoute().params.id or $route.params.id. A red flag is expecting a remount on param changes or parsing window.location manually.

easy2 min read

Create a template link to a route without a full page reload

Tests SPA client-side routing knowledge. Strong answer: name RouterLink or routerLink, explain click interception and History API URL updates, and contrast with plain anchor tags.

How do you define a basic Vue or Angular route?
easy2 min read

How do you define a basic Vue or Angular route?

Tests SPA routing conventions. Angular: Routes array in app.routes.ts with path and component, provided in bootstrap. Vue: routes array in src/router/index.js passed to createRouter. Red flag: omitting the outlet or placing config in a component.

We are hiring for this. Every open role lists the topics its interview covers, so you can prepare for the real thing rather than guessing.

See open roles