lookup method

String? lookup(
  1. String key
)

Path of the segment for key, or null when it must be rendered.

Implementation

String? lookup(String key) {
  final path = _files.remove(key);
  if (path == null) return null;
  if (!File(path).existsSync()) return null;
  _files[key] = path; // most recently used last
  return path;
}