inukshuk / citeproc-ruby

A Citation Style Language (CSL) Cite Processor
101 stars 22 forks source link

allow Renderer#render to take a hash of CSL input data #56

Open jrochkind opened 6 years ago

jrochkind commented 6 years ago

Doesn't yet have a spec/features, but needs one. I am having trouble figuring out where to fit it in to the existing spec structure how, can you advise @inukshuk on some hints as to what a good spec for this would look like? (I hope not a cucumber features, cause cucumber drives me crazy)

ref #55 ref #53

jrochkind commented 6 years ago

oops, failing travis for real. I'll look into it.

jrochkind commented 6 years ago

Uh, it looks like contrary to docs CiteProc::CitationItem was not the only legal thing to pass into Renderer#render. Something... else was being passed in in tests, which my code turns into a CiteProc::CitationItem and ruins it.

Trying to debug, but appreciate any ideas.

jrochkind commented 6 years ago

it looks like maybe everything is maybe some kind of CiteProc::Attributes, of which CiteProc::CitationItem is one example. Perhaps the doc @param should note that, not sure.

Do note that it looks like Renderer#render is used "under the hood" in things, changes we make there, if they effect performance, may effect other things than top-level manual use of Renderer#render. But I'm not too worried about it.

krzysiek1507 commented 4 years ago

Hi! Any chance to merge it?