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

Support for arbitrary CSL styles #13

Open
goerz opened this issue Jul 13, 2023 · 2 comments
Open

Support for arbitrary CSL styles #13

goerz opened this issue Jul 13, 2023 · 2 comments
Labels
enhancement New feature or request help wanted Extra attention is needed

Comments

@goerz
Copy link
Member

goerz commented Jul 13, 2023

Following up on ali-ramadhan/DocumenterCitations.jl#22 (comment), it could be nice to support arbitrary CSL styles. Even though personally, I'm happy with the new built-in styles, I just want to give an outline of how this could be implemented:

In the newly released v1.0, the CitationBibliography plugin can now be instantiated with a style keyword parameter. For the built-in styles, this is just a name (symbol). However, in general it can be an arbitrary object, enabling the "style" to have options or hold internal state. Thus, it would be conceivable to have, e.g.,

bib = CitationBibliography(
    "refs.bib";
    style=CSLStyle("chicago-author-date.csl")
)

in docs/make.jl (randomly using one of the many CSL styles as an example). The various internal DocumenterCitations routines would then receive the CSLStyle object as a parameter and specialize to generate the appropriate output.

We would be open to any PR implementing the CSLStyle and the methods to render the bibliography according to the CSL specification. Or, support for CSL could also be implemented as an independent package extending DocumenterCitations.

Maybe something that @Azzaare would be interested in.

@Azzaare
Copy link

Azzaare commented Jul 25, 2023

I can eventually, but I have too many things in my to-do list for now. So, if anyone can take care of it that would be better (sorry)

@goerz
Copy link
Member Author

goerz commented Jul 26, 2023

That's okay, it's not something I need personally :-)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request help wanted Extra attention is needed
Projects
None yet
Development

No branches or pull requests

2 participants