OkfReservedFileProjection typedef
OkfReservedFileProjection =
FutureOr<Map<String, String?> > Function(OkfProjectionInput input)
Rewrites the reserved files of a candidate during OkfBundleChangeApplier.prepare.
The result is keyed by bundle-relative path, and every key must name an
index.md or log.md file. A text replaces whatever the change set
prepared for that path; null keeps the source bundle's text, or its
absence. Paths the result does not name keep the change set's text.
The change set regenerates every ancestor index of a directory it adds,
and the Spec validator does not check where index links lead. Returning
null for the index.md of a directory the change set adds therefore
leaves its ancestors listing a missing file, so a projection that drops
such an index should also project the ancestor indexes.
Implementation
typedef OkfReservedFileProjection =
FutureOr<Map<String, String?>> Function(OkfProjectionInput input);