{
  "_args": [
    [
      "markdown-it-named-headers@https://registry.npmjs.org/markdown-it-named-headers/-/markdown-it-named-headers-0.0.4.tgz",
      "D:\\work\\3\\s\\extensions\\markdown"
    ]
  ],
  "_from": "markdown-it-named-headers@0.0.4",
  "_id": "markdown-it-named-headers@0.0.4",
  "_inCache": true,
  "_location": "/markdown-it-named-headers",
  "_phantomChildren": {},
  "_requested": {
    "name": "markdown-it-named-headers",
    "raw": "markdown-it-named-headers@https://registry.npmjs.org/markdown-it-named-headers/-/markdown-it-named-headers-0.0.4.tgz",
    "rawSpec": "https://registry.npmjs.org/markdown-it-named-headers/-/markdown-it-named-headers-0.0.4.tgz",
    "scope": null,
    "spec": "https://registry.npmjs.org/markdown-it-named-headers/-/markdown-it-named-headers-0.0.4.tgz",
    "type": "remote"
  },
  "_requiredBy": [
    "/"
  ],
  "_resolved": "https://registry.npmjs.org/markdown-it-named-headers/-/markdown-it-named-headers-0.0.4.tgz",
  "_shasum": "82efc28324240a6b1e77b9aae501771d5f351c1f",
  "_shrinkwrap": null,
  "_spec": "markdown-it-named-headers@https://registry.npmjs.org/markdown-it-named-headers/-/markdown-it-named-headers-0.0.4.tgz",
  "_where": "D:\\work\\3\\s\\extensions\\markdown",
  "author": {
    "name": "Jason Brackins"
  },
  "bugs": {
    "url": "https://github.com/leff/markdown-it-named-headers/issues"
  },
  "dependencies": {
    "string": "^3.0.1"
  },
  "description": "Headers have name attributes for markdown-it.",
  "devDependencies": {
    "markdown-it": "^4.0.1",
    "mocha": "^2.2.1",
    "test": ">=0.0.1"
  },
  "files": [
    "README.md",
    "UNLICENSE",
    "index.js"
  ],
  "homepage": "https://github.com/leff/markdown-it-named-headers",
  "keywords": [
    "markdown-it-plugin"
  ],
  "license": {
    "type": "Unlicense",
    "url": "http://unlicense.org/"
  },
  "name": "markdown-it-named-headers",
  "optionalDependencies": {},
  "readme": "# Markdown-it Named Headers\r\n\r\nA plugin for [markdown-it](https://github.com/markdown-it/markdown-it). Makes header elments have identifer attributes.\r\n\r\n```\r\n# Example Header   -->   <h1 id=\"example-header\">Example</h1>\r\n```\r\n\r\nBy default, it uses [string.js](http://stringjs.com/)'s [slugify](http://stringjs.com/#methods/slugify) to translate header text into a url safe name. You can override this. See _Options_.\r\n\r\nCribbed heavily from https://github.com/valeriangalliat/markdown-it-anchor\r\n\r\n## Install\r\n\r\n```\r\nnpm install --save-dev markdown-it-named-headers\r\n```\r\n\r\n## Usage\r\n\r\nUse with plain old node:\r\n\r\n```js\r\nvar md   = require('markdown-it'),\r\n    mdnh = require('markdown-it-named-headers');\r\n\r\nmd.use(mdnh, options);\r\n```\r\n\r\nUse as part of a Gulp workflow: (Note: You don't need to require named-headers in your gulpfile. gulp-markdown-it takes care of that for you).\r\n\r\n```js\r\nvar gulp = require('gulp'),\r\n    md = require('gulp-markdown-it');\r\ngulp.task('md', [], function() {\r\n    return gulp.src( '**/*.md' )\r\n        .pipe(md({\r\n            plugins: ['markdown-it-named-headers']\r\n        }))\r\n        .pipe(gulp.dest('dist'));\r\n});\r\n```\r\n\r\n\r\n### Options\r\n\r\n\r\n#### Slugify\r\n\r\n```js\r\n{\r\n   slugify: my_slug_function\r\n}\r\n```\r\n\r\nIf string.js's slugify doesn't fit your needs, you can simply pass in your own slugify function. Basically, the API is: accept any string, return a string suitable for a name attribute. Example:\r\n\r\n```js\r\nfunction slugify(input_string) {\r\n    var output_string = my_transform_logic(input_string);\r\n    return output_string;\r\n}\r\n```\r\n\r\nSince we use IDs, we should avoid duplicating them. A second parameter is passed. It is an empty object that will persist across a single call to render. In other words, you can use it to maintain a hash of used_headers per page.\r\n\r\nThe default slugify method looks something like this:\r\n\r\n```js\r\nfunction slugify(input_string, used_headers) {\r\n  var slug = string(input_string).slugify().toString();\r\n  if( used_headers[slug] ) {\r\n    used_headers[slug]++;\r\n    slug += used_headers[slug];\r\n  } else {\r\n    used_headers[slug] += '-' + 1;\r\n  }\r\n  return slug;\r\n}\r\n```\r\n",
  "readmeFilename": "README.md",
  "repository": {
    "type": "git",
    "url": "git+https://github.com/leff/markdown-it-named-headers.git"
  },
  "scripts": {
    "test": "mocha test/all.js"
  },
  "version": "0.0.4"
}
