We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
root
1 parent d0362f6 commit 465e406Copy full SHA for 465e406
1 file changed
src/index.js
@@ -38,6 +38,8 @@ export default (editor, opts = {}) => {
38
},
39
40
async createDirectory(zip, root) {
41
+ root = typeof root === 'function' ? await root(editor) : root;
42
+
43
for (const name in root) {
44
if (root.hasOwnProperty(name)) {
45
let content = root[name];
0 commit comments