string_normalizer 0.3.0 copy "string_normalizer: ^0.3.0" to clipboard
string_normalizer: ^0.3.0 copied to clipboard

Helps you remove accents and diacritics from strings. It comes with a built-in Crawler feature.

example/main.dart

import 'package:string_normalizer/string_normalizer.dart';

void main(List<String> args) {
  final text =
      'Thîs Is à Löngêr Strîng Wîth Môre Cõmplicâtêd Cãses Änd Diãcritics. Αυτή είναι η ελληνική φράση με ειδικούς χαρακτήρες! Αυτό είναι το νούμερο 1234.';
  final expectedText =
      'this is a longer string with more complicated cases and diacritics. αυτη ειναι η ελληνικη φραση με ειδικους χαρακτηρες! αυτο ειναι το νουμερο 1234.';
  final normalized = StringNormalizer.normalize(text).toLowerCase();
  final normalizedExtension = text.normalize().toLowerCase();
  print(normalized == expectedText); // true
  print(normalizedExtension == expectedText); // true
}
3
likes
140
pub points
78%
popularity

Publisher

verified publisherlamnhan.dev

Helps you remove accents and diacritics from strings. It comes with a built-in Crawler feature.

Repository (GitHub)
View/report issues

Documentation

API reference

License

MIT (LICENSE)

Dependencies

characters, http

More

Packages that depend on string_normalizer