Skip to content
tezvyn:

📱Mobile Dev

Mobile app development across platforms

685 bites

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

Intermediate everything in Mobile Dev, page 14

intermediate2 min read

Unit test a BLoC handling an AddItem event and emitting state

Use blocTest with build, act, expect; mention seed, skip, and mocktail for dependencies.

intermediate2 min read

How do you widget-test states without real network calls?

This tests UI isolation from I/O. Mock the repository with Mockito, stub methods to yield loading, success, and error, and inject it via constructor or provider. Avoid real HTTP calls or unmocked clients in widget tests.

intermediate3 min read

Safely gating native OS version APIs in a custom Flutter plugin

Tests platform channel contracts and defensive native coding. Gate native calls with OS version checks, return result.error with an UNSUPPORTED code, handle PlatformException in Dart, and avoid Dart-only checks.

intermediate2 min read

What is a Platform View and why is it crucial?

Tests embedding native UI when Flutter widgets fall short. Strong answers define Platform Views as native embeddings, cite maps or WebView, and contrast Hybrid Composition's native hierarchy with Virtual Display's texture rasterization.

intermediate2 min read

When to choose EventChannel over MethodChannel and native setup

It tests streaming versus one-shot platform communication. Pick EventChannel for ongoing native events like sensor data; register a StreamHandler on Android or iOS that feeds an event sink, then consume in Dart via receiveBroadcastStream.

intermediate2 min read

How would you draw a line graph using Canvas and Path?

Use moveTo for the first point, lineTo for the rest, then Canvas.drawPath with a stroke Paint.

intermediate2 min read

In a CustomPainter, what is the purpose of the shouldRepaint method?

This tests Flutter repaint optimization. Answer: shouldRepaint compares old and new delegates, returning true only when visual properties differ so the framework skips paint calls. A red flag is returning true unconditionally, forcing useless repaints.

intermediate2 min read

How does Tween work and how do you use ColorTween with Curves?

This tests value interpolation versus time remapping. A strong answer: Tween maps 0-1 to typed values; ColorTween lerps 2 colors; Curves.easeInOut warps input time before interpolation. Red flag: claiming the curve alters the color output instead of timing.

intermediate2 min read

Compare AnimatedBuilder and Transition widgets for explicit animations

Tests whether you know how explicit animations rebuild the widget tree and where to isolate animation effects. AnimatedBuilder rebuilds only its builder subtree, while Transition widgets rebuild their child when the animation ticks.

intermediate2 min read

What is an sqflite transaction? Provide a practical example.

Tests atomicity in SQLite and isolate safety. A strong answer defines all-or-nothing execution, gives a fund-transfer example updating both, and warns sqflite transactions are not cross-isolate safe. Red flag: omitting rollback or multi-isolate writes.

intermediate2 min read

Key difference between shared_preferences and flutter_secure_storage for tokens

Tests at-rest encryption: shared_preferences stores plain text XML/plist, while secure storage uses iOS Keychain and Keystore with RSA OAEP plus AES-GCM. Answers cite backup risks and hardware keys. Red flag: calling prefs safe or relying on obfuscation.

intermediate2 min read

Why is Flutter local storage async and how do you use shared_preferences?

Tests why disk I/O must avoid blocking Dart's UI thread. A strong answer shows async/await with getInstance and setters, notes legacy getters are sync-after-cache, and warns writes may not persist instantly.

intermediate2 min read

How would you manage network request state in a Flutter widget?

This tests whether you separate ephemeral widget state from business logic. A good answer defines a state class, uses setState in initState, then shows how a library moves logic out for testing and reuse. Red flag: fetch inside build or using boolean flags.

intermediate2 min read

Compare manual JSON serialization versus json_serializable

It tests build automation versus manual control in Dart serialization. Manual methods avoid build steps but risk drift; code generation cuts boilerplate but adds compile latency. Claiming code gen slows runtime or that manual is always simpler.

intermediate2 min read

Describe a robust error handling strategy for network requests

Tests whether you classify failures by layer rather than catching everything generically. Inspect DioExceptionType for connectivity, check HTTP status before parsing, and isolate JSON decode errors. Never show the same message for timeouts and 500s.

intermediate2 min read

Explain lifting state up in Flutter and how Provider simplifies it

Tests declarative state ownership and prop-drilling cost. A strong answer names the lowest common ancestor, contrasts callback threading with Provider lookup, and avoids root-level state.

intermediate2 min read

How do you manage product list and favorite state without full rebuilds?

This tests granular rebuild control in Flutter lists. A strong answer isolates item state with ValueNotifier or ChangeNotifier per item plus const constructors with keys. Red flag: calling setState on the parent list rebuilds every ListTile on each tap.

intermediate2 min read

Difference between context.watch, context.read, and Selector in Provider and Riverpod

Tests rebuild granularity in Flutter. A strong answer distinguishes listening versus one-time lookup, explains that Selector filters rebuilds by comparing sub-values, and warns that context.read inside build causes missed updates.

intermediate2 min read

Implement a GoRouter path parameter route and access userId in a widget

This tests GoRouter declarative routing and GoRouterState. Define a GoRoute with path '/users/:userId', read state.params['userId'] in the builder, and handle null-safety. A red flag is parsing the URI manually or using ModalRoute.of instead of state.params.

intermediate2 min read

Explain the core responsibilities of RouterDelegate, RouteInformationParser, and Router in Flutter

Tests Navigator 2.0 architecture split. RouteInformationParser converts URLs to typed config; RouterDelegate owns state and builds the Navigator; Router wires them together and handles engine intents. Red flag: conflating parsing and state or omitting Router.

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