Trying to integrate with this from my electron app with vue
dongkyu9315 opened this issue · comments
Hi all, thanks all for creating and maintaining this package.
I am trying to create an electron app that creates a pptx file via nodejs. I have added a dependency to this package and trying to run it, but whenever I try to import an existing pptx file, it throws below error [1], which seems like coming from this line [2]. I have listed below how to reproduce this error. Please let me know if there's anything I am missing or you need anything else to debug. Thank you so much!
[1]
(node:34950) UnhandledPromiseRejectionWarning: Error: ENOENT: no such file or directory, open '/Users/dongkyukim/workplace/hymn-lyrics-ppt-app/packages/electron-app/dist-electron/../fragments/[Content_Types].xml'
at Object.openSync (node:fs:601:3)
at Object.func [as openSync] (node:electron/js2c/asar_bundle:2:1869)
at Object.readFileSync (node:fs:469:35)
at Object.readFileSync (node:electron/js2c/asar_bundle:2:9212)
at ContentTypeFactory.build (/Users/dongkyukim/workplace/hymn-lyrics-ppt-app/packages/electron-app/dist-electron/main.js:197426:31)
at PowerPointFactory.build (/Users/dongkyukim/workplace/hymn-lyrics-ppt-app/packages/electron-app/dist-electron/main.js:204005:29)
at new PowerPointFactory (/Users/dongkyukim/workplace/hymn-lyrics-ppt-app/packages/electron-app/dist-electron/main.js:203972:10)
at new Presentation (/Users/dongkyukim/workplace/hymn-lyrics-ppt-app/packages/electron-app/dist-electron/main.js:204163:30)
at new Composer (/Users/dongkyukim/workplace/hymn-lyrics-ppt-app/packages/electron-app/dist-electron/main.js:204292:25)
at generatePPTX (/Users/dongkyukim/workplace/hymn-lyrics-ppt-app/packages/electron-app/dist-electron/main.js:205722:15)
at /Users/dongkyukim/workplace/hymn-lyrics-ppt-app/packages/electron-app/dist-electron/main.js:205781:3
at WebContents.<anonymous> (node:electron/js2c/browser_init:2:89468)
at WebContents.emit (node:events:513:28)
[2]
node-pptx/lib/factories/content-types.js
Line 12 in e9822e9
How to reproduce
git clone https://github.com/dongkyu9315/hymn-lyrics-ppt-app.git
cd hymn-lyrics-ppt-app
yarn run dev:all
(this will start an electron app)- Click the
Trigger convert
button and you will see an error
Nvm... ended up using python for pptx generation