helper-issue
Helper to create a URL that pre-populates a Github issue.
Last updated 10 years ago by doowb .
MIT · Repository · Bugs · Original npm · Tarball · package.json
$ cnpm install helper-issue 
SYNC missed versions from official npm registry.

helper-issue NPM version Build Status

Helper to create a URL that pre-populates a Github issue.

Install with npm

$ npm i helper-issue --save

Usage

var issue = require('helper-issue');

API

issue

Helper to create a URL that pre-populates a Github issue.

Params

  • repository {String|Object}: Repository string or object.
  • data {Object}: Data object to add as query parameters to the generated URL.
  • data.title {String}: Short string to populate the github issue title field.
  • data.body {String}: Markdown string to populate the github issue body field.
  • returns {String}: URL that can be used in an anchor tag.

Example

var url = issue('helpers/helper-issue', {
  title: 'Issue Title',
  body: 'Issue body that may contain markdown'
});
//=> https://github.com/helper/helper-issue/issues/new?title=Issue%20Title&body=Issue%20body%20that%20may%20contain%20markdown

Related projects

parse-github-url: Parse a github URL into an object. | homepage

Running tests

Install dev dependencies:

$ npm i -d && npm test

Contributing

Author

Brian Woodward

License

Copyright © 2015 Brian Woodward Released under the MIT license.


This file was generated by verb on December 22, 2015.

Current Tags

  • 0.3.0                                ...           latest (10 years ago)

4 Versions

  • 0.3.0                                ...           10 years ago
  • 0.2.0                                ...           11 years ago
  • 0.1.1                                ...           11 years ago
  • 0.1.0                                ...           11 years ago
Maintainers (1)
Downloads
Today 0
This Week 0
This Month 0
Last Day 0
Last Week 0
Last Month 1
Dependencies (1)
Dev Dependencies (3)
Dependents (1)

Copyright 2013 - present © cnpmjs.org | Home |