Inspect the project, run it locally, and use each lesson's checks to observe what actually happens on the server and in the browser.
A complete App Router application with catalogue routing, cart state, a task dashboard, practice sessions, tenant checks, cached data, hydration repairs, and HTTP streaming. Next.js 16.4.6 and React 19.3.0 are pinned in the project.
The playground opens a new editable copy. A local Node.js 22.14+ installation also runs the project. Use the local production build when measuring caching, streaming, or deployment behavior.
Terminal
cd nextjs-interview-lab
npm ci
npm run dev
# In a second terminal
npm test
# Stop dev, then verify the production application
npm run build
npm start
# In a second terminal, install the test browser once
npx playwright install chromium
npm run test:e2e
Open http://localhost:3003. The project includes a credential-free practice account selector and a single-process file store. Those choices make experiments reproducible; the security and deployment lessons show what a production system needs.
TRANSFER THE SKILL
Build under interview conditions.
Choose a brief, set your own timer, and work before opening the approach. The suggested timeboxes are practice targets, not claims about the original interviews.
BUILD 0190 min practice
Shareable product and research explorer
Build an original catalogue application informed by the public SimplifyJobs ecommerce and ModernVivo explorer patterns. The dataset can contain products or papers. A reader must search, filter, paginate, open details and keep a saved list across navigation. Framework-specific cache and failure requirements are FrontendX extensions.
Build requirements
Server-render a catalogue and a dynamic detail route from a validated data adapter.
Keep query, filter, sort and page in the URL; preserve unrelated parameters and reset the page when filters change.
Implement saved items with a deliberate client or server persistence contract and visible pending/error states.
Include empty, slow, failed and unknown-item routes with accessible feedback.
Explain the selected cache lifetime and mutation invalidation behavior.
Acceptance checklist and solution approach
Verify your work
Copying a filtered URL into a fresh tab reproduces the same result selection.
Back/forward navigation restores the expected query and page.
A stale request cannot replace a newer query result.
Unknown records have a real not-found outcome; failures do not look like empty successful lists.
A keyboard user can search, open a result and save an item.
Worked approach
Start with the data contract: normalize query values, bound page size and return a stable DTO with IDs, display fields and pagination metadata. Keep secrets and upstream adaptation in the server-only data layer.
Implement the server catalogue page and detail page before styling every card. Await current route parameters and decide which data is public/cacheable versus request-specific.
Use a small client filter form that updates URL state. Preserve other search parameters, reset pagination deliberately and make the first server snapshot agree with the browser.
Put saved-item interaction in a client boundary or an authorized action according to the persistence requirement. Distinguish speculative state from the confirmed result and reconcile by operation identity.
Add a loading boundary, empty result message, route error boundary and not-found result. Associate form errors with inputs and preserve focus during background refresh.
Verify a direct nested URL, copy/paste, refresh, history, a slow earlier search response and a failed save. Measure a real route rather than calling a byte-budget exercise a performance test.
Defend these decisions
How would search change for ten million records?
What happens if one product changes while another tab is open?
Which data should be cached by query and which should remain user-specific?
Create an original organization dashboard informed by the public WorkOS user-management and task-manager assignment patterns. Users can read and edit permitted documents. The learning objective is to prove the resource boundary through real requests, not to copy a vendor integration.
Build requirements
Provide two demonstration users with distinct tenant or owner permissions.
Render a protected list and edit form with server-validated fields.
Keep the authoritative identity in the server session, and return a minimal public DTO.
Implement an ownership/tenant predicate at every callable data and mutation boundary.
Use a version or another explicit conflict policy for simultaneous edits.
Acceptance checklist and solution approach
Verify your work
A direct request with another tenant's record ID is denied without altering data.
A valid owner can save and immediately observe the confirmed value.
Validation errors preserve the draft and identify the affected field.
A stale-version write is rejected or handled according to a documented conflict policy.
Logout is verified by a fresh protected request, not only the disappearance of a button.
Worked approach
Write a permission table before endpoints. Separate who the actor is from what action they may perform on a target document, and define whether admin is tenant-scoped.
Create a server-only DAL that resolves trusted identity, scopes the record query and returns only displayable fields. Reuse that layer from pages, actions and handlers.
Implement a narrow validation function and a typed action result. Do not accept ownerId, tenantId or role from the form as authority.
Keep permission and version predicates in the same conditional write, or use a transaction with the required guarantees. A prior read followed by an unconstrained update leaves a race window.
After success, invalidate the relevant tagged data and obtain a confirmed route view. Explain how a browser query cache, if present, is updated separately.
Test both allowed and denied requests, concurrent versions, expired identity and a changed record ID. Label demonstration storage honestly and describe the production adapter needed for durable multi-instance behavior.
Defend these decisions
How does a changed role invalidate old signed claims?
How would audit events avoid leaking sensitive content?
What if the mutation commits but its response is lost?
Which layer should rate-limit writes across replicas?
Build an original searchable selection flow informed by the public reusable-select assignment. Add Next.js server-rendered initial data, a shareable selected ID and a hydration repair challenge. Accessibility and execution reasoning are evaluated alongside the visible dropdown.
Build requirements
Provide a labeled searchable selection control using a documented accessible primitive or a correctly implemented keyboard pattern.
Load initial options on the server and keep the first browser snapshot consistent.
Handle slow search, cancellation, an empty result and failed loading.
Persist a selected ID in the URL while keeping the typed draft local until the chosen commit policy.
Support long labels, 320px width, both themes and reduced motion.
Acceptance checklist and solution approach
Verify your work
The complete interaction can be performed with a keyboard and exposes an accessible name.
A slow earlier response does not replace newer results.
The selected ID survives refresh and browser history.
No hydration error is hidden with a blanket suppression or whole-page SSR disable.
Focus remains predictable after selection, dismissal and a loading failure.
Worked approach
Define the control states and keyboard behavior first. Prefer native elements or a proven accessible primitive when its semantics match the requirement; a styled div alone does not implement a combobox.
Create the server option DTO and pass it into the smallest client boundary. Use stable IDs and the same selected value for server markup and the first browser render.
Keep the search draft separate from the committed URL selection. Normalize and validate the selected ID server-side before using it to fetch a protected resource.
Cancel obsolete fetch work and guard completion with request identity. Present loading, no results and failure as different states.
Use flexible text layout, visible focus and a meaningful status announcement. Verify translated or long labels without clipping the active option.
Add a race test and a keyboard flow, then intentionally introduce a browser-only initial read and explain why it causes a mismatch before repairing it.
Defend these decisions
How would virtualization change keyboard and screen-reader behavior?
When should typing replace rather than push browser history?
How would the control work without client JavaScript?
What if the selected record is no longer available?
Create an original content-generation and publication dashboard informed by the public Adsgency scaffold. Use a deterministic local worker instead of requiring a paid AI service. Add bounded input, progress streaming, cancellation and publication freshness as FrontendX extensions.
Build requirements
Accept a validated request and expose an operation ID with explicit queued/running/succeeded/failed states.
Stream or poll progress using a documented endpoint contract.
Cancel per-subscriber work and prevent duplicate event application.
Publish a successful result through an authorized mutation with deliberate cache invalidation.
Clearly distinguish a demonstration in-memory job loop from a durable production queue design.
Acceptance checklist and solution approach
Verify your work
A malformed request fails before expensive work begins.
Disconnecting a subscriber does not leak its timer or subscription.
Duplicate or older progress events do not regress the displayed state.
Publication is permitted only for an authorized completed result.
A failed worker produces a recoverable state rather than endless loading.
Worked approach
Define the operation state machine and allowed transitions before implementing the worker. Give every logical operation a stable ID, and separate worker ownership from one browser subscription.
Create a Route Handler for the HTTP contract, validate content type and input limits, and return stable error schemas with meaningful statuses.
For SSE, frame events with IDs and blank-line termination. A continuing producer must handle abort and cancellation; arbitrary network chunks are not complete events.
Use a reducer that ignores old versions and preserves completed or failed outcomes according to the protocol. Reconnection requires an explicit replay or fresh-snapshot strategy.
Authorize publication on the server and confirm the durable write before invalidating the public content cache. Do not expose internal prompts, credentials or private metadata in the public DTO.
Test invalid input, disconnect, repeated delivery, a worker error and a publish attempt by another identity. Explain which lifecycle guarantees require a durable queue and persistent operation store beyond the demonstration.
Defend these decisions
What happens after a server restart?
How are progress events routed across multiple application instances?
Should a retried publication create a duplicate item?
How would you accept a large uploaded source file safely?
Build an original authentication practice extension informed by public organization-auth assignment patterns. Implement a jose-signed HttpOnly cookie session, synchronize a verified server snapshot with the client and demonstrate the limits of stateless logout. Use only local demonstration identities, never real credentials.
Build requirements
Use an established jose signing and verification API with pinned algorithm, issuer, audience and required expiry claims.
Keep the signing key in server-only configuration and issue the cookie only after a trusted demonstration login decision.
Render a minimal verified session DTO into the server response and use the same snapshot for client hydration.
Refresh the server-derived session view after login/logout and clear private client caches.
Document local cookie removal, copied-token validity, role freshness, key rotation and immediate-revocation trade-offs.
Acceptance checklist and solution approach
Verify your work
A normal reload preserves the session without a per-session database row.
A tampered, expired, wrong-audience or malformed token is rejected on the server.
The login view has no initial client/server mismatch caused by localStorage.
Logout removes the browser cookie and the next protected request is denied.
The report explicitly states that a copied stateless token remains valid until expiry unless additional revocation state or key policy rejects it.
Worked approach
Define the session contract: a short-lived signed token contains minimal identity and timing claims, while the server holds a stable cryptographically random signing secret. No session database does not mean no state.
Use SignJWT and jwtVerify from jose. Require sub, iat and exp, pin the allowed algorithm and expected issuer/audience, and do not treat decode-only payload inspection as authentication.
Set an HttpOnly cookie with a deliberate Secure, SameSite and path policy. Explain that the browser sends it automatically on matching requests; the client does not need the raw token or signing key.
In a request-specific server boundary, await cookies, verify the token and construct a small session DTO. Pass that DTO into a client provider that reads updated props rather than retaining useState(initialSession) forever.
After cookie-changing actions, use the chosen server redirect or refresh flow. Invalidate private client state and guard against delayed old-session responses. Test direct protected requests as well as the visible menu.
Demonstrate the revocation limitation with a controlled local test token. Explain why a denylist, session version or online identity service adds state, why short expiry bounds rather than eliminates the window, and why a valid signed role may be stale.
Defend these decisions
How would JWE change confidentiality without solving revocation?
How do signing keys differ from bearer tokens and public verification keys?
What breaks if each replica generates its own key at startup?
Run an original debugging round that combines recurring public interview concepts with official runtime caveats. Seed five defects: divergent initial auth state, a fetch waterfall, stale post-mutation UI, an authorization bypass and a deployment configuration mistake. This is a FrontendX synthesis, not a copied employer test.
Build requirements
Reproduce each defect and write the broken invariant before editing.
Repair hydration without hiding the warning or disabling the entire server render.
Parallelize independent reads while preserving meaningful loading boundaries.
Coordinate the actual server and client caches used by the mutated view.
Fix resource authorization and verify production configuration without exposing secrets.
Acceptance checklist and solution approach
Verify your work
Each repair has a check that fails before the change and succeeds afterward.
The browser and server initial session snapshots agree.
An unauthorized direct mutation is denied even when the UI is bypassed.
The selected cache freshness promise is demonstrated after a write and a second read.
The handoff distinguishes executed runtime checks from reviewed source and blocked environments.
Worked approach
Establish a baseline using direct route loads, client navigation, a mutation and a second identity. Record the actual build/runtime version and chosen caching model so historical assumptions do not contaminate the diagnosis.
Trace hydration values to their sources. Replace a browser-only initial auth decision with the server-verified snapshot, keeping later session refresh behavior explicit.
Start independent data operations before awaiting them and place Suspense boundaries where partial content is meaningful. Confirm the improvement through response timing rather than an assumed faster label.
Identify the cache owner of the stale widget. Invalidate the relevant server tag or path and update/refetch its browser query entry if one exists; avoid indiscriminate global invalidation.
Move the resource permission predicate into the trusted DAL or conditional write. Test a changed ID, another tenant and an expired session.
Review public environment inlining, server runtime support and deployment consistency. Finish with exact checks and limits, then explain which small change fixed each invariant and why alternative symptom-suppression fixes were rejected.
Defend these decisions
Which repair changes if the route uses the Pages Router?
What if the bug appears only behind a buffering reverse proxy?
How does the cache design change across three replicas?
Which tests should remain as regression protection?
The course combines public assignments, published question patterns, and current official documentation. The exercises and explanations are written for FrontendX. This is a broad coverage map, not an exhaustive archive of every question online.
Ecommerce pages, mock API, layouts and dynamic routes. Original scaffold uses Next.js 13 and React 18; this course modernizes the mechanisms rather than copying that implementation.
Authentication, organization membership and server-generated widget tokens. The course practices provider-independent permission checks instead of reproducing the vendor integration.
Search, details and persisted important flags with an external backend. Public assignment evidence, not a claim about the company’s current hiring process.
Generation, publication and dashboard HTTP APIs with service boundaries, types and logging. Public scaffold, not independently verified hiring-process evidence.
Selection invariants, fetched data and a results modal. Older Pages Router and effect-based loading requirements are labeled historical rather than taught as universal defaults.
Server-only credentials, streaming chat, image input and failure states. Our exercises use deterministic mock data and do not require that provider or paid credentials.
Full-stack UI controls, pricing rules, GraphQL contracts and event subscriptions. The course derives general state and integration exercises without copying the assignment.
Published June 9, 2026. Question-pattern evidence for routing, rendering, hydration, secrets and stale data. Technical explanations are checked against primary documentation.
Public concept, output-prediction and code-writing prompts. Its claimed verification version is 16.4.3. We do not copy its answers or treat its claims as independently executed evidence.