新手问题 想问下 ruby 有 word 的模板引擎吗

a886937 · May 16, 2018 · Last by a886937 replied at May 18, 2018 · 1433 hits

写 word 文件像是写 vue.js 或是 avalon2.js 一样的模板,另外同样求 pdf 的,额好吧,其实这是前端需求。。

为啥要用 ruby,pandoc 了解一下

自己写一个,2007 的 MS word 就是一个 zip 文件,打开后有很多配置文件,自己写个逻辑处理占位符就行。部署在 linux 很好用,比啥 open office 强多了。

$ pandoc --extract-media ./doc ./test.docx -o ./test.html

$ pandoc --extract-media ./doc ./test.pdf -o ./test.html

ruby 中也有相应的 gem: pandoc-ruby

谢谢各位,我了解一下

a886937 closed this topic. 21 May 09:22
You need to Sign in before reply, if you don't have an account, please Sign up first.