A piece of code to slim down HTML5 module exported by Adobe Captivate.
Checkout CPExternalizer CLI for command line interface or CPExternalizer GUI for graphical interface. See CPCluster example to get the whole scenarios for using these tools.
const cpext = require('cpexternalizer');
CPExternalizer exposes 4 methods each of which returns a promise to chain.
{Array.<String>}
src
File paths to CPM.js exported by Adobe Captivate.{String}
outdir
Where to save output. Default is the current directory.
Extracting the initiator(s) from src
and export them to outdir
.
{Array.<String>}
src
File paths to CPM.js exported by Adobe Captivate.{String}
outdir
Where to save output. Default is the current directory.{String}
samplePath
path to sample CPM.js file
Extracting components in CPM.js which are not covered in sample CPM.js at the moment.
{Array.<String>}
src
input folders{String}
outdir
where to save
Process folders (exported by Adobe Captivate) and return a "slimmed down" one containing only CPProjInit.js, ar and dr.
{Array.<String>}
src
file path or directory to find CPProjInit{String}
ulpath
file path or directory of common unit loader
Fix the audio path in CPProjInit. All non-js files will be ignored.