tolerantUtf8 top-level constant

Utf8Codec const tolerantUtf8

UTF-8 codec that replaces malformed bytes with U+FFFD instead of throwing.

Use it for anything that can carry raw device or app output: logs.txt, flutter run output, adb logcat, log show, idevicesyslog. Pass it as stdoutEncoding/stderrEncoding to Process.run, or use tolerantUtf8.decoder on a process stream.

Implementation

const tolerantUtf8 = Utf8Codec(allowMalformed: true);