Use main pdfkit repo
diegomura opened this issue ยท 4 comments
I'd like to remove pdfkit fork and start using https://github.com/foliojs/pdfkit again. I branched from this a long time ago for multiple reasons, so I'm not sure the lift here. It will mean for sure to add several changes in that repo, which I think it could benefit the entire community, but not sure yet what those are.
I'll keep this issue as a sort of umbrella issue where I'll capture all the differences and report progress as I tackle them. It will be a slow path.
- Dedupe png-js here
- Font classes
- Line wrapper missing on our fork. We don't really need this, but we will need to ship it if we unify
- Object class differences
- Add user units param to page in original repo
- Path file differences
- Reference file differences
- Security file differences
- Virtual fs missing
- Use jay-peg instea of jpeg-exif here
- EmbedImage method
- Add PDF/a mixins
- Text mixing multiple differences
- Add PageMode and PageLayout to pdfkit
- Multiple document class differences
- Remove node dep for loading default fonts
Hey, regarding png-js bit - consider pngjs too! See my comment: #676 (comment)
Thanks! Just took a quick look, and pngjs has node deps too, meaning I'll need to fork it as for now, or have them onboard on shipping a browser build. And also convince pdfkit to adopt this. Because pdfkit already uses png-js the path towards unifying this is shorter, but I'll check what would be more convenient
@foliojs Can you kindly pitch in and add your thoughts here?
@diegomura Hi!
I am getting this error the @swc/helpers@0.4.11 with the react-pdf/render and i am using the next 13v
I do all the others way like cache clean , node module delete and reinstall and change the next version but didnt get any solution to resolve this issue
is there any way to resolved this issue
materio-mui-react-nextjs-admin-template@2.0.0 D:\alyzone\n-travel-scheduler\n_travel_web_dash
โโโฌ @react-pdf/renderer@3.4.5
โ โโโฌ @react-pdf/font@2.5.2
โ โโโฌ fontkit@2.0.4
โ โโโ @swc/helpers@0.5.13
โโโฌ next@13.0.0
โโโ @swc/helpers@0.4.11
error - ./node_modules/fontkit/dist/browser-module.mjs:2:0
Module not found: Can't resolve '@swc/helpers/_/_define_property'
Import trace for requested module:
./node_modules/@react-pdf/font/lib/index.browser.js
./node_modules/@react-pdf/renderer/lib/react-pdf.browser.es.js
./src/pages/to/accounting/invoices/list/index.js
https://nextjs.org/docs/messages/module-not-found
