react-component-academic-reference

1.0.5 • Public • Published

react-component-academic-reference

A react component library for using and displaying academic references.

❗️❗️❗️❗️❗️❗️❗️❗️❗️❗️❗️❗️❗️❗️❗️❗️❗️❗️❗️❗️❗️❗️❗️❗️❗️❗️

❗️❗️❗️THIS IS CURRENTLY A WORK IN PROGRESS ❗️❗️❗️

❗️❗️❗️❗️❗️❗️❗️❗️❗️❗️❗️❗️❗️❗️❗️❗️❗️❗️❗️❗️❗️❗️❗️❗️❗️❗️

GET IN TOUCH if you're interested in this component 😄

https://raw.githubusercontent.com/georgegillams/react-component-academic-reference/master/example/screenshot.png

Usage

import {
  citation,
  References,
  REFERENCE_STYLES
} from "react-component-academic-reference";
 
const myReferences = [
  {
    citationKey: 'SAMPLE1',
    entryType: 'ARTICLE',
    entryTags: { title: 'sample title', author: 'sample author' },
  },
  {
    citationKey: 'SAMPLE2',
    entryType: 'ARTICLE',
    entryTags: { title: 'sample title', author: 'sample author' },
  },
  {
    citationKey: 'SAMPLE3',
    entryType: 'ARTICLE',
    entryTags: { title: 'sample title', author: 'sample author' },
  },
];
 
 
const Cite = citation(myReferences);
 
const Article = props => (
  <main>
    Lorem ipsem dolor sit <Cite identifier="SAMPLE1" />.
    <br />
    <References
      referenceStyle={REFERENCE_STYLES.harvard}
      references={myReferences}
    />
  </main>
);

As time goes on I hope I / the open-source community will add support for multiple reference and citation formats.

Compatibility

This is compatible with bibtex-parse-js, which converts bibtex to a JSON object. Usage of this component with bibtex-parse-js can be seen in the example app code here.

Contributing

If you're interested in this project, please get in touch. I will add details on how to contribute directly once I have implemented the basic features.

Future Work

  • Fix reference style to match Harvard specification
  • Add different styles for Citations (ie CITATION_STYLES) so that citations can appear in a different format to [3].
  • Anything else you can think of 😉
  • Add support for multiple identifiers per citation (to output Some cited text [14, 20].)

Readme

Keywords

none

Package Sidebar

Install

npm i react-component-academic-reference

Weekly Downloads

2

Version

1.0.5

License

MIT

Unpacked Size

15.9 kB

Total Files

8

Last publish

Collaborators

  • georgegillams