Skip to content
pubscout

enough_convert

1.7.1, released 7 weeks ago by enough.de

Support for character encodings and codecs missing from dart:convert.

WASM-ready
$ flutter pub add enough_convert
Source repository

What it does

Provides implementation for character encodings, charsets, and codecs missing from the standard dart:convert library. Supports ISO 8859 (Latin), Windows codepages, DOS codepages, GBK, Big5, and KOI8 R/U. Allows encoding and decoding text in legacy formats.

AI-written summary of version 1.7.1, based on the package's README and metadata. Report an inaccuracy

Use it when

  • You need to parse or generate text using legacy character encodings like ISO 8859 or Windows codepages.
  • You are dealing with older web pages, emails, or data streams that do not use UTF-8.

Skip it when

  • Your application exclusively uses modern UTF-8 or standard encodings already built into dart:convert.

Strengths

  • Supports a wide range of legacy character sets including Latin, Windows, DOS, GBK, Big5, and KOI8.
  • Fully null-safe and lightweight with no external dependencies.
  • Provides custom codec extensibility if you need to implement your own.

Weaknesses

  • Limited to text encoding conversions only.

Setup

Kind
Pure Dart
Effort
Low
Code generation
No
Direct dependencies
0
import 'package:enough_convert/enough_convert.dart';

main() {
  final codec = const Windows1252Codec(allowInvalid: false);
  final input = 'Il faut être bête quand même.';
  final encoded = codec.encode(input);
  final decoded = codec.decode([...encoded]);
  print('${codec.name}: encode "$input" to "$encoded"');
  print('${codec.name}: decode $encoded to "$decoded"');
}

Alternatives

Packages that do the same job and could replace enough_convert.

Works with

Packages commonly used together with enough_convert: ones it builds on, ones built on it, and its own family.