ggabbiani / orthodocs

OrthoDocs is a documentation generator and static analysis tool for OpenSCAD source trees.
GNU General Public License v3.0
3 stars 0 forks source link

Implement a writer for HTML or PDF #1

Open stockiNail opened 1 year ago

stockiNail commented 1 year ago

Currently there is only 1 writer, to markdown.

It could be helpful to have different writers, for instance for HTML or PDF. Furthermore, this feature could also enable a writer for framework (i.e. VuePress, Docusaurus) , based on MD, which are creating a complete doc site to publish somewhere (i.e. GH pages).

It could be better that these "plugins" could be coded also in other programming languages.

ggabbiani commented 1 year ago

Ciao Stock,

the currently implemented extensions are just the ones I needed for a project of mine, but the design is extendible and I had in mind other plugins for both writer and language plugins. The html writer is a planned feature for the next release, c++ language is another of the things I'd like to implement ... eventually.

Support for plugin written in programming language other than C++

A quick and dirty solution is to just export the analytic document in json format, making it possible to write anything else from there. In this case OrthoDocs would be used only for the analytics. I don't like this approach because it complicates things for the final user but it could be implemented very quickly.

A more complete solution would be to move the extension mechanism from static to dynamic and to write a 'general' configurable extension able to trigger an external program after having produced the export of the analytic documents and conveniently transcoded the input parameters.

Does it make sense for you?

Cheers Giampiero

stockiNail commented 1 year ago

A more complete solution would be to move the extension mechanism from static to dynamic and to write a 'general' configurable extension able to trigger an external program after having produced the export of the analytic documents and conveniently transcoded the input parameters.

I think this makes a lot of sense.