punycode_converter 0.2.1 punycode_converter: ^0.2.1 copied to clipboard
A robust Punycode converter that fully complies to RFC 3492 and RFC 5891.
example/punycode_converter_example.dart
import 'package:punycode_converter/punycode_converter.dart';
void main() {
final uri = Uri.parse('http://тетрадкадружбы.рф/страница');
print(uri.punyEncoded);
print(uri.punyEncoded.punyDecoded);
print(uri.punyEncoded.punyEncoded);
final uri2 = Uri.parse('http://example.com/some-page');
print(uri2.punyEncoded);
print(uri2.punyEncoded.punyDecoded);
print(uri2.punyEncoded.punyEncoded);
print(Punycode.domainEncode('bücher.com'));
}