quarto-journals / jss

Quarto template for the Journal of Statistical Software
GNU General Public License v3.0
22 stars 5 forks source link

Not possible to set class options #5

Closed devmotion closed 2 years ago

devmotion commented 2 years ago

The doc-class.tex partial does not support class options such as shortnames, nojss, or e.g. bookreview. I'm not sure what's more desirable and in particular what's the typical approach in Quarto: Just looping over the class options (as in the default template) or supporting only some specific ones in a journal namespace, similar to https://github.com/quarto-journals/elsevier?

dragonstyle commented 2 years ago

I think the biggest question is whether the format should support any options or whether it makes sense to be more restrictive (e.g. only certain options should be allowed since others ultimately won't be respected when actually typesetting the article). I don't have a ton of experience here and would expect this to vary journal to journal, so am completely open minded, especially if you have experience or feedback!

devmotion commented 2 years ago

I agree, I would guess it varies depending on how restrictive the class file of a journal is. From a quick look it seems that jss.cls only processes the options article/codesnippet/bookreview/softwarereview (mutually exclusive), shortnames, nojss, notitle, noheadings, and nofooter. So in this case, I assume it would be reasonable to also restrict the Quarto template to these class options?

dragonstyle commented 2 years ago

Yeah that definitely makes sense to me, and I definitely had the general instinct that more restrictive is better (at least as a way to discover what options should be supported!).

Perhaps something like:

format:
  jss-pdf:
    type: article | codesnippet | bookreview ...
    cite-shortnames: true
    suppress: [title | headings | footer]
    include-jss-layout: false

For cite-shortnames, it would be sweet if we add a filter that could just count authors in references and enable shortnames automatically.

devmotion commented 2 years ago

Fixed by #6.