You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Normalizer: an option to write named library folders after the media #148
normalizeArchive sorts every library folder before content/, with the media last (orderEntries). That is the right order for what plays. It is the wrong one for libraries a package carries and nothing reads as it plays: the editor libraries an H5P site's upload check asks for, which h5p-author's packages and the demo's now carry (#146, #147).
In a package with media they end up before content/content.json, so a host that ignores Range has to deliver them before the frame can boot. On the demo's video (an Interactive Video, 5.2 MB with them) the content now ends at 4.1 MB; without them it ended at 1.5 MB. A package without media keeps the order h5p-author writes, libraries, content, then these, because h5p-author normalizes only a package that has media. So only packages with media are affected, and Interactive Video and Course Presentation are the ones whose editors are large.
Proposal
normalizeArchive({ input, output, last }): last is a list of top-level folders written after everything else, the media included, each whole and in the order the source had them. content is never moved, a name the archive has no folder for is ignored, and a string is refused rather than read as letters. Without last nothing changes, so it is a minor. No command-line flag: only the package's author knows which folders those are.
Activity