Live data from Hacker News

Show HN: DOM-docx – HTML to native, editable Word docs (MIT)

github.com

41–43 of 43 posts

Re: Show HN: DOM-docx – HTML to native, editable Word docs (MIT)

#41
post #2

Hey HN, author here. I do a lot of backend document (docx file) generation work, and updating our templates and backend code is one of my least favorite development tasks. Cryptic errors, minute-plus rebuild loops. I’d much prefer building these reports in JS rendered HTML (e.g., Vue or React), but existing HTML-to-docx libraries in the OSS ecosystem don't produce output that's actually valid, editable Word structure…

This is very cool and thanks for sharing the workflow, buuuuuut... Could you please rewrite the README in your own words? If not for this comment, I would have just flagged this submission without looking into it further, because no matter how useful the premise is, it feels like one of the millions “I’ve burnt a bunch of tokens and thrown the result on GitHub” kinda projects you see nowadays. Clearly that’s not the…

I hear you, thanks for the feedback. I've done that some already but of course it could be better in more of my own voice.

Re: Show HN: DOM-docx – HTML to native, editable Word docs (MIT)

#42
post #2

Hey HN, author here. I do a lot of backend document (docx file) generation work, and updating our templates and backend code is one of my least favorite development tasks. Cryptic errors, minute-plus rebuild loops. I’d much prefer building these reports in JS rendered HTML (e.g., Vue or React), but existing HTML-to-docx libraries in the OSS ecosystem don't produce output that's actually valid, editable Word structure…

Very interesting approach. I am having trouble with page breaks (documentation says they work, but demo pages dont) etc. For the invoicing example this would require table breaks/overflows into subsequent pages in a real application and I am currently evaluating going with model->PDF or model->DOCX Do you have any approach in this regard that works ?

I tested this, but it seems like it regressed somehow. It may not be working in the browser side use case right now. I'll have to look at it later this evening. I created a GH issue to keep it on the radar: https://github.com/floodtide/dom-docx/issues/5

Could you update the GH issue with a bit more information about your specific use case?

Re: Show HN: DOM-docx – HTML to native, editable Word docs (MIT)

#43

Earlier quoted context omitted.

Very interesting approach. I am having trouble with page breaks (documentation says they work, but demo pages dont) etc. For the invoicing example this would require table breaks/overflows into subsequent pages in a real application and I am currently evaluating going with model->PDF or model->DOCX Do you have any approach in this regard that works ?

I tested this, but it seems like it regressed somehow. It may not be working in the browser side use case right now. I'll have to look at it later this evening. I created a GH issue to keep it on the radar: https://github.com/floodtide/dom-docx/issues/5 Could you update the GH issue with a bit more information about your specific use case?

I fixed this issue. The dom-docx.com Live Converter "Try in the browser" page was running an older version of the dom-docx package from before Page Breaks were added as a feature. I've updated it to the latest version.
Post reply on HN