1.6.1 • Published 1 year ago

react-readme-printer v1.6.1

Weekly downloads
-
License
MIT
Repository
github
Last release
1 year ago

react-readme-printer 👋

Provides a function to load a readme file from github repositories and a React component to automatically load and convert markdown to jsx

Installation

npm i react-readme-printer

Demo 👀

https://axelmry.com/react-readme-printer (...with code 😉)

Usage 💻

import React from 'react'
import { MarkdownPrinter } from 'react-readme-printer'

const Example = () => {
    return (
        <MarkdownPrinter
            username='axelmy318'
            repository='react-readme-printer'
            branch='master'
            file='custom_readme_name'
        />
    )
    
}

export default Example

Dependencies

This project relies on react-markdown to convert the markdown files to JSX

API ✔

Propertiestypedefaultdescription
usernamestringnullThe GitHub username
repositorystringnullThe GitHub repository from which to fetch the README.md
branchstring"main"The branch on which to fetch the README.md
filestring"README"The filename of the readme file. The .md is automatically added
showRepositorybooltrueWether to show the repository name or not. See examples
markdownConfigobject{}The props to pass down to the ReactMarkdown component
convertHtmlImgToMarkdownboolfalseWether to convert <img src='foo_bar> tags into npm.io or not
1.6.1

1 year ago

1.6.0

1 year ago

1.5.2

1 year ago

1.5.1

1 year ago

1.5.0

1 year ago

1.4.0

2 years ago

1.2.2

2 years ago

1.3.0

2 years ago

1.2.1

2 years ago

1.2.0

2 years ago

1.1.3

2 years ago

1.1.2

2 years ago

1.1.1

2 years ago

1.0.1

2 years ago

1.0.0

2 years ago

0.2.3

2 years ago

0.2.2

2 years ago