structured_field_values 1.0.0 copy "structured_field_values: ^1.0.0" to clipboard
structured_field_values: ^1.0.0 copied to clipboard

A Dart native implementation of Structured Field Values for HTTP (RFC 9651)

example/structured_field_values_example.dart

// Allow print for demos
// ignore_for_file: avoid_print

import 'package:structured_field_values/structured_field_values.dart';

void main() {
  // Parsing an HTTP header value using the specialized codec
  const headerValue = 'a=?0, b, c;foo=bar';
  final parsed = structuredDictionary.decode(headerValue);
  print('Parsed dictionary: $parsed');

  // Serializing back to a header value string
  final serialized = structuredDictionary.encode(parsed);
  print('Serialized header: $serialized');
}
2
likes
160
points
81
downloads

Documentation

API reference

Publisher

verified publisherdropbear.dev

Weekly Downloads

A Dart native implementation of Structured Field Values for HTTP (RFC 9651)

Repository (GitHub)
View/report issues

License

MIT (license)

Dependencies

collection, meta

More

Packages that depend on structured_field_values