getSettings method

Future<Settings> getSettings(
  1. String path
)

Implementation

Future<Settings> getSettings(String path) async {
  final content = await fs.file(path).readAsString();

  final settings = checkedYamlDecode(
    content,
    (e) => Settings.fromJson(e ?? {}),
    sourceUrl: Uri.parse(path),
  );

  return settings;
}