Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Documentation for CSL Plugins incorrect?

See original GitHub issue

I think the CSL Plugins docs may need to change Cite.plugins.output.config.get('csl') to Cite.plugins.config.get('@csl')?

Similar to #161, I was getting undefined errors whenever I tried to call Cite.plugins.config.get. I was following the instructions in the CSL Plugins docs. After some struggling, I found Cite.plugins.list() under the plugins docs, used it, found that csl is actually @csl. I then tried to register my CSL template with Cite.plugins.config.get('@csl'), and found it worked.

Here’s the full working code excerpt:

const references = fs.readFileSync('_input/citations/bib.json', 'utf8')

let cite = new Cite(references)

let stylesName = 'josh-csl'
let styles = fs.readFileSync('_input/citations/styles.csl', 'ascii')
Cite.plugins.config.get('@csl').templates.add(stylesName, styles)

var testCitation = cite.format('citation', {
    format: 'html',
    template: stylesName,
    lang: 'en-US',
    entry: ['wallace-wells2019']


citation-js@0.5.0-alpha.4, node v12.12.0, macOS 10.15

Issue Analytics

  • State:closed
  • Created 4 years ago
  • Comments:7 (3 by maintainers)

github_iconTop GitHub Comments

leafaccommented, Apr 30, 2020
larsgwcommented, Nov 23, 2021

Let’s carry this on in if you want.

Read more comments on GitHub >

github_iconTop Results From Across the Web

Citation Language Style plugin bug: Issue year should have ...
The citation by the CSL plugins shows 2020 as publication year, but it should be 2019. They don't want to re-date the publication...
Read more >
@citation-js/plugin-csl | Yarn - Package Manager
Important: This documentation covers modern versions of Yarn. For 1.x docs, see Yarn.
Read more >
An unexpected error occurred while installing .csl file
I disabled all add-ons and tried "Reset styles'' from Advanced > Files and foleders. I am using Zotero on Win10. Can any...
Read more >
How to reconfigure csl path? - xPilot - VATSIM Community
Within X-Plane, go to the Plugins menu and find xPilot and open the Settings window. Reference the xPilot documentation if you need further ......
Read more >
Authors - Citation Style Language
We recommend first checking your software tool's documentation to learn their recommended way of finding and installing CSL styles. For instance, some tools ......
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Post

No results found

github_iconTop Related Hashnode Post

No results found