fromJSON static method

ThemeCustomizer fromJSON(
  1. String? json
)

Implementation

static ThemeCustomizer fromJSON(String? json) {
  instance = ThemeCustomizer();
  if (json != null && json.trim().isNotEmpty) {
    JSONDecoder decoder = JSONDecoder(json);
    instance.theme =
        decoder.getEnum('theme', ThemeMode.values, ThemeMode.light);
  }
  return instance;
}