@farberg/reveal-template 1.0.61 → 1.0.62
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/init-reveal.js +19 -13
- package/package.json +1 -1
package/init-reveal.js
CHANGED
|
@@ -198,23 +198,29 @@ export function initReveal(opts) {
|
|
|
198
198
|
window.Reveal = Reveal
|
|
199
199
|
|
|
200
200
|
//Add markdown doc to presentation
|
|
201
|
-
|
|
201
|
+
const doc = getDocumentToLoadOrRedirectToIndexDocument(options)
|
|
202
202
|
|
|
203
|
-
|
|
204
|
-
|
|
203
|
+
if (doc) {
|
|
204
|
+
addMarkdownSectionToPresentation(doc, options);
|
|
205
205
|
|
|
206
|
-
|
|
207
|
-
|
|
208
|
-
...modules,
|
|
209
|
-
...defaultDennisPlugins,
|
|
210
|
-
window.RevealChalkboard,
|
|
211
|
-
...finalOptions.plugins
|
|
212
|
-
]
|
|
206
|
+
//Initialize Reveal
|
|
207
|
+
const finalOptions = Object.assign(defaultRevealOptions, options.revealOptions);
|
|
213
208
|
|
|
214
|
-
|
|
215
|
-
|
|
209
|
+
//Add plugins
|
|
210
|
+
finalOptions.plugins = [
|
|
211
|
+
...modules,
|
|
212
|
+
...defaultDennisPlugins,
|
|
213
|
+
window.RevealChalkboard,
|
|
214
|
+
...finalOptions.plugins
|
|
215
|
+
]
|
|
216
216
|
|
|
217
|
-
|
|
217
|
+
if (options.verbose)
|
|
218
|
+
console.log("Invoking Reveal.initialize with options: ", finalOptions)
|
|
219
|
+
|
|
220
|
+
Reveal.initialize(finalOptions);
|
|
221
|
+
} else {
|
|
222
|
+
console.error("No document to load, aborting");
|
|
223
|
+
}
|
|
218
224
|
|
|
219
225
|
}).catch(error => {
|
|
220
226
|
console.error("Unable to load dependencies: ", error);
|