Dashboard dash,
CdfRunJsDashboardWriteOptions options,
boolean bypassCacheRead )
throws ThingWriteException {
// 1. Obtain a Writer for the CdfRunJs format
CdfRunJsThingWriterFactory writerFactory = new CdfRunJsThingWriterFactory();
CdfRunJsDashboardWriter writer = writerFactory.getDashboardWriter( dash );
// 2. Write it
CdfRunJsDashboardWriteContext writeContext = CdeEngine.getInstance().
getEnvironment().getCdfRunJsDashboardWriteContext( writerFactory, /*indent*/"", bypassCacheRead, dash, options );