citeproc_writer: citeproc writer

Description Usage Arguments Value See Also Examples

View source: R/citeproc_writer.R

Description

citeproc writer

Usage

1
citeproc_writer(z, auto_unbox = TRUE, pretty = TRUE, ...)

Arguments

z

an object of class handl; see handl for more

auto_unbox

(logical) automatically "unbox" all atomic vectors of length 1 (default: TRUE). passed to jsonlite::toJSON()

pretty

(logical) adds indentation whitespace to JSON output (default: TRUE), passed to jsonlite::toJSON()

...

further params passed to jsonlite::toJSON()

Value

citeproc as JSON

See Also

Other writers: bibtex_writer(), cff_writer(), codemeta_writer(), rdf_xml_writer(), ris_writer(), schema_org_writer()

Other citeproc: citeproc_reader()

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
z <- system.file('extdata/citeproc.json', package = "handlr")
(tmp <- citeproc_reader(z))
citeproc_writer(z = tmp)
citeproc_writer(z = tmp, pretty = FALSE)
cat(ris_writer(z = tmp))

# many
z <- system.file('extdata/citeproc-many.json', package = "handlr")
w <- citeproc_reader(x = z)
citeproc_writer(w)

handlr documentation built on Jan. 13, 2021, 7:27 a.m.