{"id":19889631,"url":"https://github.com/moimikey/react-footnotes","last_synced_at":"2025-05-02T17:33:47.108Z","repository":{"id":47699558,"uuid":"145918573","full_name":"moimikey/react-footnotes","owner":"moimikey","description":"👣 dead simple footnotes, in React","archived":false,"fork":false,"pushed_at":"2023-11-02T22:20:09.000Z","size":444,"stargazers_count":5,"open_issues_count":1,"forks_count":2,"subscribers_count":3,"default_branch":"main","last_synced_at":"2024-08-10T05:03:52.194Z","etag":null,"topics":["footnote","footnotes","react","react-components"],"latest_commit_sha":null,"homepage":"","language":"JavaScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/moimikey.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null}},"created_at":"2018-08-23T23:38:18.000Z","updated_at":"2023-10-12T21:39:58.000Z","dependencies_parsed_at":"2023-11-02T23:24:58.270Z","dependency_job_id":null,"html_url":"https://github.com/moimikey/react-footnotes","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/moimikey%2Freact-footnotes","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/moimikey%2Freact-footnotes/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/moimikey%2Freact-footnotes/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/moimikey%2Freact-footnotes/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/moimikey","download_url":"https://codeload.github.com/moimikey/react-footnotes/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":224324404,"owners_count":17292521,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["footnote","footnotes","react","react-components"],"created_at":"2024-11-12T18:10:58.477Z","updated_at":"2024-11-12T18:10:58.579Z","avatar_url":"https://github.com/moimikey.png","language":"JavaScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# 👣 react-footnotes\n\ndead simple footnotes, in React\n\n\u003cimg width=\"399\" alt=\"react-footnotes\" src=\"https://user-images.githubusercontent.com/182661/44605190-611d5980-a7b6-11e8-858b-0e640965a7b6.png\"\u003e\n\n\n## Installation\n\n```sh\nnpm install --save react-footnotes\nyarn add react-footnotes\n```\n\n```js\n// esmodules\nimport { Footnotes } from 'react-footnotes'\n\n// commonjs\nvar Footnotes = require('react-footnotes').Footnotes\n```\n\n## Usage\n\nPass any props you want to read from `getFootnotes`, to `Footnote`.\n\n```jsx\nimport * as React from 'react'\nimport { Footnotes } from 'react-footnotes'\n\nclass App extends React.Component {\n  render() {\n    return (\n      \u003cFootnotes\u003e\n        {({ Footnote, getFootnotes }) =\u003e (\n          \u003cReact.Fragment\u003e\n            \u003cFootnote i={1} desc={`this is a description.`}\u003eLorem ipsum dolor sit amet, consectetur adipiscing elit.\u003c/Footnote\u003e Text that doesnt need to be footnoted, can be passed as normal text.\n            \u003cFootnote i={2} desc={`this is a description.`}\u003eUt enim ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo consequat.\u003c/Footnote\u003e\n            \u003cFootnote i={3} desc={`this is a description.`}\u003eDuis aute irure dolor in reprehenderit in voluptate velit esse cillum dolore eu fugiat nulla pariatur.\u003c/Footnote\u003e\n            \u003cFootnote i={4} desc={`this is a description.`}\u003eExcepteur sint occaecat cupidatat non proident, sunt in culpa qui officia deserunt mollit anim id est laborum.\u003c/Footnote\u003e\n            \u003col\u003e\n              {Object.keys(getFootnotes()).map(i =\u003e {\n                return (\n                  \u003cli key={`footnote-${i}`} id={`footnote-${i}`}\u003e{getFootnotes()[i].desc}\u003c/li\u003e\n                )\n              })}\n            \u003c/ol\u003e\n          \u003c/React.Fragment\u003e\n        )}\n      \u003c/Footnotes\u003e\n    )\n  }\n}\n```\n\n## TODO\n\n- [ ] automatically generate the index number so it doesn't have to be passed manually...\n\n## Development\n\n```sh\nnpm run dev\n\n# go to http://localhost:1234\n```\n\n### Distribution\n\n```sh\nnpm run build\n```\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmoimikey%2Freact-footnotes","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fmoimikey%2Freact-footnotes","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmoimikey%2Freact-footnotes/lists"}