dvStudioEffectiveEdges function

Map<DVDocumentSlot, String> dvStudioEffectiveEdges(
  1. Map<Object?, Object?> document,
  2. Map<Object?, Object?> files
)

The HTML each slot comes to, from the settings and the file contents files (path to text) a build or a project supplied. A file nobody supplied comes to nothing rather than failing the screen.

Implementation

Map<DVDocumentSlot, String> dvStudioEffectiveEdges(Map<Object?, Object?> document, Map<Object?, Object?> files) {
  final DVPlatformSettingsRead read = DVPlatformSettings.fromPubspec(<String, Object?>{
    'web': <String, Object?>{'document': document},
  });
  return dvResolveDocumentSlots(
    read.settings.web.document,
    readFile: (String path) => '${files[path] ?? ''}'.trimRight(),
  );
}