getStringList static method

Future<List<String>?> getStringList(
  1. String key
)

Reads a string array value from persistent storage under the specified app group.

If the persistent storage does not contains key, then null will be returned

Implementation

static Future<List<String>?> getStringList(String key) async {
  final List? receivedArray = await _channel.invokeMethod('getStringArray', {'key': key});
  if (receivedArray != null) {
    return receivedArray.cast<String>();
  }
  return null;
}