protected static method

Future<TSharedProtectedPod> protected(
  1. String key, {
  2. String? initialValue,
})

Implementation

static Future<TSharedProtectedPod> protected(
  String key, {
  String? initialValue,
}) async {
  final instance = TSharedProtectedPod(
    key,
    fromValue: (rawValue) => rawValue,
    toValue: (value) => value,
    initialValue: initialValue,
  );
  await instance.refresh();
  return instance;
}