Skip to content
tezvyn:

Vue, Angular & Svelte

Vue 3, Nuxt, Angular, Svelte, SvelteKit

67 bites

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

Intermediate interview questions in Vue, Angular & Svelte, page 3

intermediate2 min read

How do you test emitted events using Vue Test Utils?

Tests Vue Test Utils event inspection. Strong answer: mount, trigger('click'), then check wrapper.emitted('increment') for the payload array. Remember it returns an array of arrays, one per emission.

How do you mock an async service call in an Angular component test?
intermediate2 min read

How do you mock an async service call in an Angular component test?

This tests Angular unit isolation and HTTP mocking. A strong answer covers HttpTestingController setup, flushing a mock response, asserting UI changes, and notes mocking avoids flaky networks. Red flag: using real HTTP calls in unit tests.

intermediate2 min read

How do you test a Svelte component updates a writable store?

Import the store with the component, render, await fireEvent.click, then assert the store value.

Describe the role of a spy in testing with a framework example
intermediate2 min read

Describe the role of a spy in testing with a framework example

This tests whether you know a spy records calls without replacing original implementation. A strong answer defines the tracking role, picks a concrete Vue or Angular handler, and asserts with toHaveBeenCalled.

Why is Svelte called a 'disappearing framework'?
intermediate2 min read

Why is Svelte called a 'disappearing framework'?

Tests whether you understand compile-time versus runtime-heavy frameworks. A strong answer says Svelte compiles components to vanilla JS at build time, shipping a tiny runtime instead of a reconciler or virtual DOM. Red flag: claiming there is zero runtime.

intermediate2 min read

How is a Vue template compiled into a render function?

Map v-if to ternaries, v-for to array map, and events to onXxx props.

intermediate2 min read

Compare Angular Zone.js and Vue 3 Proxy reactivity

This tests update granularity. Contrast Vue 3 Proxy tracking, targeting only affected components, with Angular Zone.js patching async APIs to trigger top-down dirty checking across tree. Vue binds deps at render; Angular compares values each cycle.

intermediate2 min read

Hydration: SSR HTML to interactive app?

Server renders HTML, client JavaScript bootstraps and attaches event listeners (hydration), mismatch occurs if server HTML differs from client render.

How do you create a POST API endpoint in SvelteKit?
intermediate2 min read

How do you create a POST API endpoint in SvelteKit?

Add a +server.js file in a src/routes subdirectory, export a POST handler returning a Response, and note that +server files never run in the browser.

Explain server.ts and main.ts in Angular Universal
intermediate2 min read

Explain server.ts and main.ts in Angular Universal

Server.ts SSRs initial HTML via Node/Express; main.ts bootstraps the browser app and hydrates the DOM. First request hits the server; later navigations are client-side only.

How does Angular's Zone.js change detection differ from Vue and Svelte reactivity?
intermediate2 min read

How does Angular's Zone.js change detection differ from Vue and Svelte reactivity?

Tests granular reactivity architecture. Angular Zone.js monkey-patches async to scan the full component tree; Vue uses runtime Proxy tracking; Svelte compiles runes into targeted DOM bindings.

How do Vue, Angular, and Svelte handle deep prop mutation re-rendering?
intermediate2 min read

How do Vue, Angular, and Svelte handle deep prop mutation re-rendering?

Vue and Svelte detect nested mutations via Proxies; Angular default re-renders via Zone.js, but ngOnChanges misses it since the reference is unchanged.

Create a custom synchronous validator for an Angular Reactive Form
intermediate2 min read

Create a custom synchronous validator for an Angular Reactive Form

Tests your grasp of the ValidatorFn contract and reactive form wiring. A strong answer: a function accepting AbstractControl returns null when valid or an error object when invalid, passed as the second FormControl argument. Red flag: returning booleans.

intermediate2 min read

How would you structure a scalable store for interconnected domains?

Tests domain-driven state partitioning and cross-slice derived data. Strong answers use feature slices, normalized entities, and memoized selectors; keep computed state out of the store. Red flag: a monolithic state tree with component-level recomputation.

intermediate2 min read

How would you implement a memoized selector for expensive derived state?

It tests cache invalidation and pure functions for reactive derived state. A strong answer covers reference tracking on inputs, returning cached results when unchanged, and requiring immutable or stable arguments.

How would you unit-test a Svelte date utility with Vitest?
intermediate2 min read

How would you unit-test a Svelte date utility with Vitest?

This question tests isolating pure logic from Svelte and configuring Vitest. A good answer covers installing Vitest, co-locating a spec file, and asserting known inputs. A red flag is insisting you must mount a Svelte component to test a plain function.

intermediate2 min read

AOT vs JIT compilation: what does ahead-of-time win?

AOT compiles templates at build time (catches errors early, smaller bundle, faster startup), JIT compiles in browser (slower startup, larger bundle, flexible).

How does ngc work in Angular AOT and what artifacts improve performance?
intermediate2 min read

How does ngc work in Angular AOT and what artifacts improve performance?

This tests understanding of AOT build-phase compilation and output. Cover efficient JS output, inlined templates and styles cutting AJAX requests, and removal of compiler payload roughly half of Angular. Red flag: conflating AOT and JIT or calling it bundling.

What is Angular Ivy's 'locality' and its benefits over View Engine?
intermediate2 min read

What is Angular Ivy's 'locality' and its benefits over View Engine?

Tests Ivy's per-file compilation model. Locality compiles decorators to static properties without global knowledge, except components need their NgModule scope, speeding builds and tree-shaking.

intermediate1 min read

Server-side data fetching in Nuxt 3?

Use useFetch or useAsyncData to fetch on server, data is serialized and injected into page state, component accesses it as reactive data.

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