Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Can templates be overridden with the standalone CLI? #349

Closed
darinpope opened this issue Feb 26, 2020 · 3 comments · Fixed by #351
Closed

Can templates be overridden with the standalone CLI? #349

darinpope opened this issue Feb 26, 2020 · 3 comments · Fixed by #351

Comments

@darinpope
Copy link

Based on the enhancement list from 4.0.0:

Built-in slim templates can now be overridden with --template-dir or -T

I'm not seeing that it is working with the standalone macOS version:

asciidoctor-revealjs --version
Asciidoctor reveal.js 4.0.1 using Asciidoctor.js 2.1.1 (Asciidoctor 2.0.10) [https://asciidoctor.org]
Runtime Environment (node v12.13.1 on darwin)

I did see in one of the related issues that it might only apply to Ruby and not the other flavors/distros.

Should template override work with the standalones?

@obilodeau
Copy link
Member

--template-dir is only available using the Ruby platform. I realize that documentation is lacking in that regard. I'll update it. The related issue you were talking about is #177.

@Mogztter do you think something can be done for the asciidoctor.js side (w/ standalone being supported as well as a bonus)? It could be pug templating instead of tilt/slim. I believe that would be easier. Is this PR (asciidoctor/asciidoctor.js#770) helping in any way or it would need to be an unrelated implementation?

@ggrossetie
Copy link
Member

--template-dir is only available using the Ruby platform. I realize that documentation is lacking in that regard. I'll update it. The related issue you were talking about is #177.

Indeed, Asciidoctor.js does not (yet) have a template converter.

do you think something can be done for the asciidoctor.js side (w/ standalone being supported as well as a bonus)? It could be pug templating instead of tilt/slim. I believe that would be easier. Is this PR (asciidoctor/asciidoctor.js#770) helping in any way or it would need to be an unrelated implementation?

Yes asciidoctor/asciidoctor.js#770 is related. It will probably be included in Asciidoctor.js 2.2.0.
I also have a prototype where I'm using ERB templates (compiled to JavaScript using Opal) but it won't work with Tilt/Slim templates (I mean, in theory, it could but I don't want to spend time cross-compiling Slim to JavaScript)

@obilodeau
Copy link
Member

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants