{"name":"unist-util-generated","version":"1.1.6","description":"unist utility to check if a node is generated","license":"MIT","keywords":["unist","unist-util","util","utility","position","location","generated"],"repository":{"type":"git","url":"git+https://github.com/syntax-tree/unist-util-generated.git"},"bugs":{"url":"https://github.com/syntax-tree/unist-util-generated/issues"},"funding":{"type":"opencollective","url":"https://opencollective.com/unified"},"author":{"name":"Titus Wormer","email":"tituswormer@gmail.com","url":"https://wooorm.com"},"contributors":[{"name":"Titus Wormer","email":"tituswormer@gmail.com","url":"https://wooorm.com"}],"devDependencies":{"browserify":"^17.0.0","nyc":"^15.0.0","prettier":"^2.0.0","remark-cli":"^9.0.0","remark-preset-wooorm":"^8.0.0","tape":"^5.0.0","tinyify":"^3.0.0","xo":"^0.34.0"},"scripts":{"format":"remark . -qfo && prettier . -w --loglevel warn && xo --fix","build-bundle":"browserify . -s unistUtilGenerated -o unist-util-generated.js","build-mangle":"browserify . -s unistUtilGenerated -o unist-util-generated.min.js -p tinyify","build":"npm run build-bundle && npm run build-mangle","test-api":"node test","test-coverage":"nyc --reporter lcov tape test.js","test":"npm run format && npm run build && npm run test-coverage"},"nyc":{"check-coverage":true,"lines":100,"functions":100,"branches":100},"prettier":{"tabWidth":2,"useTabs":false,"singleQuote":true,"bracketSpacing":false,"semi":false,"trailingComma":"none"},"xo":{"prettier":true,"esnext":false,"ignores":["unist-util-generated.js"]},"remarkConfig":{"plugins":["preset-wooorm"]},"gitHead":"e843d6c89785a97d757c1c0b22c8bdf3c834f28c","homepage":"https://github.com/syntax-tree/unist-util-generated#readme","_id":"unist-util-generated@1.1.6","_nodeVersion":"14.13.1","_npmVersion":"6.14.8","dist":{"integrity":"sha512-cln2Mm1/CZzN5ttGK7vkoGw+RZ8VcUH6BtGbq98DDtRGquAAOXig1mrBQYelOwMXYS8rK+vZDyyojSjp7JX+Lg==","shasum":"5ab51f689e2992a472beb1b35f2ce7ff2f324d4b","tarball":"http://registry-npm.ywwl.com/unist-util-generated/download/unist-util-generated-1.1.6.tgz","fileCount":4,"unpackedSize":6465,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.13\r\nComment: https://openpgpjs.org\r\n\r\nwsFcBAEBCAAQBQJfoC5LCRA9TVsSAnZWagAAiQcP/35vVUyqSJDGN5N2piws\nzc7CMEJASRQstqG034soQ4SG9kCjACGnD5JAe8Lzps0/gTKLbIJLJwGAkVon\n1EODbH3YfmNDjDWWj0CX0juUuzp9uXKP9l+vf4zPhEKPaYeaNqEDkyR7aAkG\nArAcTyaxV+riOFec7gLc+DkqSOWdA6IrDsHGcnbE5/vID/aFwYUoOAeCXes1\nfGz5Ir71B1wiZSCFiSZI75bKwfY3YlmeygicxNObVl1R4zxxwmfM6lpVUoNh\n6YNyQPVL/bLw8/zxHfLQ/Cz8ySZs03aWTOTTmWO6u2sHhi/E6lZQXxhX4SJp\ntLDz3u8qAW8hBje4wl/mOHm6x33eIKi+R7lRtDXXVJdyKEwu9J9Ul9h1rIlR\niHVyY1CBZCbGdpr9K//80xP2bu3VKv4OD8LGyWWgpG7yJ4NJoVV9osV0zXfa\niLNb1yRKO7/tY48ewNrAsKu9xtXfBAg6NmDQjK3qEN1ZRAJyaHl2yXWKsQmm\nFrq0GBHG0S1E+pKvrqEMvk2/UbAF0AkVM9/+vcqR9/zhBg+wO+mM6iANnjg4\nRh9gJpbbKUIQUSW2mwOZMwrkF2k82QPXHcMhTXfk9k6IM8XuCv+i2BSmIyOp\netxrtS13dNCdpvM7SZzDGDbodoq2NzRNw+3mSsXghe/oW7Tvw4vRyuuNo9gr\nrB/H\r\n=9sVz\r\n-----END PGP SIGNATURE-----\r\n","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEQCIC+/1WK/QUpKuFyOB8jKAGi9eBta3MaG0bMl1H4ZWGYAAiAkzzYGeBMRIcAEaXgZVXmsmVZdXySbMPfvQjR9tomdug=="}],"size":2618,"noattachment":false,"key":"/unist-util-generated/-/unist-util-generated-1.1.6.tgz"},"maintainers":[{"name":"kmck","email":"keith@mcknig.ht"},{"name":"wooorm","email":"tituswormer@gmail.com"}],"_npmUser":{"name":"wooorm","email":"tituswormer@gmail.com"},"directories":{},"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/unist-util-generated_1.1.6_1604333130552_0.050386898091923094"},"_hasShrinkwrap":false,"readme":"# unist-util-generated\n\n[![Build][build-badge]][build]\n[![Coverage][coverage-badge]][coverage]\n[![Downloads][downloads-badge]][downloads]\n[![Size][size-badge]][size]\n[![Sponsors][sponsors-badge]][collective]\n[![Backers][backers-badge]][collective]\n[![Chat][chat-badge]][chat]\n\n[unist][] utility to check if a node is generated.\n\n## Contents\n\n*   [What is this?](#what-is-this)\n*   [When should I use this?](#when-should-i-use-this)\n*   [Install](#install)\n*   [Use](#use)\n*   [API](#api)\n    *   [`generated(node)`](#generatednode)\n*   [Types](#types)\n*   [Compatibility](#compatibility)\n*   [Related](#related)\n*   [Contribute](#contribute)\n*   [License](#license)\n\n## What is this?\n\nThis utility can be used to check if a node is said to be\n[generated][generated-term].\n\n## When should I use this?\n\nYou can use this utility to check is generated.\nGenerated nodes were not in the source of the original file, and thus not\nauthored by a human.\nThis info can then be used to not emit lint messages for generated content.\n\nYou might also find the utility [`unist-util-position`][unist-util-position]\nuseful to get clean positional info.\nTo display positional info to users, use\n[`unist-util-stringify-position`][unist-util-stringify-position].\n\n## Install\n\nThis package is [ESM only][esm].\nIn Node.js (version 16+), install with [npm][]:\n\n```sh\nnpm install unist-util-generated\n```\n\nIn Deno with [`esm.sh`][esmsh]:\n\n```js\nimport {generated} from 'https://esm.sh/unist-util-generated@3'\n```\n\nIn browsers with [`esm.sh`][esmsh]:\n\n```html\n<script type=\"module\">\n  import {generated} from 'https://esm.sh/unist-util-generated@3?bundle'\n</script>\n```\n\n## Use\n\n```js\nimport {generated} from 'unist-util-generated'\n\ngenerated({}) // => true\n\ngenerated({position: {start: {}, end: {}}}) // => true\n\ngenerated({\n  position: {start: {line: 1, column: 1}, end: {line: 1, column: 2}}\n}) // => false\n```\n\n## API\n\nThis package exports the identifier [`generated`][generated].\nThere is no default export.\n\n### `generated(node)`\n\nCheck if `node` is generated.\n\n###### Parameters\n\n*   `node` ([`Node`][node])\n    — node to check\n\n###### Returns\n\nWhether `node` is generated (does not have positional info) (`boolean`).\n\n## Types\n\nThis package is fully typed with [TypeScript][].\nIt exports no additional types.\n\n## Compatibility\n\nProjects maintained by the unified collective are compatible with maintained\nversions of Node.js.\n\nWhen we cut a new major release, we drop support for unmaintained versions of\nNode.\nThis means we try to keep the current release line, `unist-util-generated@^2`,\ncompatible with Node.js 16.\n\n## Related\n\n*   [`unist-util-position`](https://github.com/syntax-tree/unist-util-position)\n    — get the position of nodes\n*   [`unist-util-source`](https://github.com/syntax-tree/unist-util-source)\n    — get the source of a node or position\n*   [`unist-util-remove-position`](https://github.com/syntax-tree/unist-util-remove-position)\n    — remove `position`s\n*   [`unist-util-stringify-position`](https://github.com/syntax-tree/unist-util-stringify-position)\n    — serialize positional info\n\n## Contribute\n\nSee [`contributing.md`][contributing] in [`syntax-tree/.github`][health] for\nways to get started.\nSee [`support.md`][support] for ways to get help.\n\nThis project has a [code of conduct][coc].\nBy interacting with this repository, organization, or community you agree to\nabide by its terms.\n\n## License\n\n[MIT][license] © [Titus Wormer][author]\n\n<!-- Definition -->\n\n[build-badge]: https://github.com/syntax-tree/unist-util-generated/workflows/main/badge.svg\n\n[build]: https://github.com/syntax-tree/unist-util-generated/actions\n\n[coverage-badge]: https://img.shields.io/codecov/c/github/syntax-tree/unist-util-generated.svg\n\n[coverage]: https://codecov.io/github/syntax-tree/unist-util-generated\n\n[downloads-badge]: https://img.shields.io/npm/dm/unist-util-generated.svg\n\n[downloads]: https://www.npmjs.com/package/unist-util-generated\n\n[size-badge]: https://img.shields.io/badge/dynamic/json?label=minzipped%20size&query=$.size.compressedSize&url=https://deno.bundlejs.com/?q=unist-util-generated\n\n[size]: https://bundlejs.com/?q=unist-util-generated\n\n[sponsors-badge]: https://opencollective.com/unified/sponsors/badge.svg\n\n[backers-badge]: https://opencollective.com/unified/backers/badge.svg\n\n[collective]: https://opencollective.com/unified\n\n[chat-badge]: https://img.shields.io/badge/chat-discussions-success.svg\n\n[chat]: https://github.com/syntax-tree/unist/discussions\n\n[npm]: https://docs.npmjs.com/cli/install\n\n[esm]: https://gist.github.com/sindresorhus/a39789f98801d908bbc7ff3ecc99d99c\n\n[esmsh]: https://esm.sh\n\n[typescript]: https://www.typescriptlang.org\n\n[license]: license\n\n[author]: https://wooorm.com\n\n[health]: https://github.com/syntax-tree/.github\n\n[contributing]: https://github.com/syntax-tree/.github/blob/main/contributing.md\n\n[support]: https://github.com/syntax-tree/.github/blob/main/support.md\n\n[coc]: https://github.com/syntax-tree/.github/blob/main/code-of-conduct.md\n\n[unist]: https://github.com/syntax-tree/unist\n\n[node]: https://github.com/syntax-tree/unist#node\n\n[generated-term]: https://github.com/syntax-tree/unist#generated\n\n[unist-util-position]: https://github.com/syntax-tree/unist-util-position\n\n[unist-util-stringify-position]: https://github.com/syntax-tree/unist-util-stringify-position\n\n[generated]: #generatednode\n","publish_time":1604333130683,"_cnpm_publish_time":1604333130683,"dist-tags":{"latest":"3.0.0"}}