Duolith docs

Errors E0400 to E0499

E0432 Mock in a native build

Message name is a mock, and a native build does not ship one

Words in italics are filled in when the compiler reports it, such as the element's name or the list of known ones.

Why

A mock, such as mockBiometrics or mockLocation, is a stand-in platform that answers what it is told: mockBiometrics passes every check, and mockStore grants every purchase. It is for tests, and for trying an app in a desktop browser. A native build is what reaches the App Store and Google Play, so it refuses to compile a page or component that imports one, rather than ship an app that only pretends (decision 0102).

How to fix it

Use the mock in a test, or in a web build to try the app, and leave it out of the pages and components the native build compiles. Each effect's own platform is used when nothing replaces it with use().

In a terminal

duolith explain E0432

Mentioned in