-1

I'm looking for all existent possibilities to convert an HTML document to a DOCX one.

Context :

I have some documentation that it's written and maintained in HTML (No complex thing, just simples H1, H2, P, IMG elements), and I would like to convert them into word documents.

A Maven plugin would be great, or something that could allow me to do this conversion during the release phase of my application.

Jean-Michel Garcia
  • 2,359
  • 2
  • 23
  • 44

1 Answers1

2

Disclosure: docx4j is "my" project

docx4j can do this, for well-formed XHTML. See the ConvertInXHTML* examples.

docx4j-ImportXHTML is in Maven Central: https://search.maven.org/artifact/org.docx4j/docx4j-ImportXHTML/8.0.0/jar

If you want a Maven plugin, you'll have to create that yourself.

JasonPlutext
  • 15,352
  • 4
  • 44
  • 84