6
LeMeow
7d

- Need a module to work with PDFs
- npm install
- But wait, that requires some dependencies
- And those dependencies require more dependencies
- Python not found
- Issues with env variables and wsl
*Bajillion hours later*
- poppler-qt5 not found
What the hecc is a poppler and why do I need it?
:/

Comments
  • 5
    @LeMeow

    Why ...

    Javascript?

    Oh Lord why?

    And poppler is one of the few major libraries for PDF.

    If u have questions feel free to ask... But Javascript seems like a very bad choice.
  • 4
    Perhaps run a microservice in docker that handles pdf generation natively, instead of using library upon library
  • 1
    @IntrusionCM I have everything installed, including poppler, and it still doesn't work.

    Node JS because it wasn't anything big that I wanted to get done and I thought I could get it up and running quickly; Doesn't feel that way now...
  • 1
    @alexbrooklyn I just have to use existing Pdfs and edit them, found several libraries that could do that, but ran into these problems. :/
  • 2
    Use docker and create microservice in real language, that has native bindings to poppler (or other real library). This is the only real solution for you if you can't "just install" what you need.
  • 0
    @LeMeow If u want help, describe your problem precisely.

    The most simple jobs can be done utilizing either library or command line.
  • 4
    Python... Npm... Why those two are in the same context? 😱
  • 1
    NodeJS,
    wasn't something big,
    doesn't work.

    seriously do you even Node?

    None of those statements go together.
  • 0
    @IntrusionCM

    So, I have an excel file as input and I have to extract data from it and fill (existing) PDF form for each record, generating n PDF forms for n records in the excel file.

    I was learning and practicing Node properly and I thought that it should be possible to do this with node. I guess I was wrong and should have done more research on proper ways to do this (?). @C0D4
  • 2
    @LeMeow K.

    PDF Forms are using FDF / XDFDF.

    Maybe there is a Javascript library out there that can handle creation.

    Otherwise - pdftk can write a form with data to a PDF file.

    Most libraries I remember don't fill the form directly, instead they either extract it and replace the existing form or they simply place text commands at the formular fields positions.

    First one requires a library that can handle extraction and replacement of the FDF/XFDF Part, last one is simpler - but might fail (if the receiving part simply extracts the FDF/XFDF stream there is no information ;)).

    Maybe that helps pinpointing which specific library you want to use.

    In PHP, it's usually FPDF (Seti / commercial) or TCPDF (Open Source).
  • 1
    @IntrusionCM how i love and yet hate hate FPDF.

    @LeMeow there is fpdf-njs , I haven't used it, but it states it's built based on fpdf which is freaking awesome once you get over its issues and learning curve.
  • 2
    @COD4 Oh yes.

    PDF - fucking bazillion standards, always a surprise to open a file and not knowing if it's pandoras box or usable.
  • 0
    Poppler is like the derpiest name you can give to a piece of software. I fucking lost it at “what the hecc is a poppler”!
Your Job Suck?
Get a Better Job
Add Comment