pub fn generate_import_block<'a>(
exprs: impl IntoIterator<Item = &'a CodecExpr>,
) -> Result<String, Vec<DiagnosticKind>>Expand description
Generate the import block for a set of expressions.
Always starts with import * as r from 'rkyv-js';, followed by named
imports grouped by module and sorted by module specifier
(exports sorted within each statement).
The same export name imported from two different modules is reported as
DiagnosticKind::ImportConflict.