file-contributors
TypeScript icon, indicating that this package has built-in type declarations

1.0.2 • Public • Published

👩🏽‍💻 file-contributors 👨🏻‍💻

Ever wonder who's contributed to a specific file on github? file-contributors gives you simple way to get all contributors to a specific file on Github.

🤖 See over-engineered demo on codesandbox

⚡️ Installation

Install file-contributors from npm

npm install file-contributors --save

Usage

file-contributors exports function that accepts 3 arguments.

  • owner Owner of the github repository. This could be your username or organization name
    • type: String
  • repo Name of the repository
    • type: String
  • path Location of the file relative to the repository root.
    • type: String
import getFileContributors from 'file-contributors'
 
const file = {
  owner: 'codebender828',
  repo: 'file-contributors',
  path: 'README.md'
}
 
const contributors = getFileContributors(file.owner, file.repo, file.path)
  .then(contributors => {
    console.log(contributors) // Logs array of contributors to file.
  })

❤️ Support this project

If you like this project, please consider supporting it by buying my a coffee!

Buy me a coffee
Made with ❤️ by Jonathan Bakebwa 🇺🇬

Dependents (1)

Package Sidebar

Install

npm i file-contributors

Weekly Downloads

4

Version

1.0.2

License

MIT

Unpacked Size

6.91 kB

Total Files

9

Last publish

Collaborators

  • _codebender828