{"name":"@node-rs/helper","version":"0.4.0","description":"Helper library for node-rs","keywords":["N-API","napi","Rust","Performance"],"author":{"name":"LongYinan","email":"lynweklm@gmail.com"},"homepage":"https://github.com/napi-rs/node-rs","license":"MIT","main":"lib/index.js","typings":"lib/index.d.ts","publishConfig":{"registry":"https://registry.npmjs.org/","access":"public"},"repository":{"type":"git","url":"git+https://github.com/napi-rs/node-rs.git"},"bugs":{"url":"https://github.com/napi-rs/node-rs/issues"},"dependencies":{"tslib":"^2.0.1"},"gitHead":"02661406422e2c4995a9062a3859138a7b9eb7a7","_id":"@node-rs/helper@0.4.0","_nodeVersion":"12.18.3","_npmVersion":"lerna/3.22.1/node@v12.18.3+x64 (linux)","dist":{"integrity":"sha512-fSyHEXmlt/FueKqAYiGFCnkohnQBMQwUr6VYPeZEeVBAzQzhioS1WaRe2fSpOuRKIimCQEvxhQ6fwsYxYakfGA==","shasum":"deec7d95aafa90535980a51cbd5336b8bbefe93a","tarball":"http://registry-npm.ywwl.com/@node-rs/helper/download/@node-rs/helper-0.4.0.tgz","fileCount":8,"unpackedSize":7670,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.4\r\nComment: https://openpgpjs.org\r\n\r\nwsFcBAEBCAAQBQJfUmryCRA9TVsSAnZWagAA7hoP/1yiB9iMlqrbo7G86uif\nZdjYdRMIdOqcicBG31iVmcGdtHA5j3e08hi811BeMCyaFjE7yV0u1Zx5Z34Z\nxcRloWnEk2dikcAoM3SQmiyIIALZe24S/P5j+agA5wqaZByzOU763rH0crXO\nIx3QP7QJoPUq3l5E6YVNOEOfEpSdEaDtqLUO16tvqWXH9Mff+dhQSpIBhslH\nKQOcKSAWgLmeCxoFhRyxCv0geVu6pTNkQfRhtpJpmUUxpmh3jKvfLc3jVlJ4\ndSWzK+hIE3p+pP9qrW60WcgHgIhyYHSIwEozozveelTyu9hHedBrMa2iE6cZ\nbTtbsZ0y1H+gs7WSp/0e3P/Nn4aqC0RKZca5GR2rc4B3KGbFYQ9lGvsZ4sD0\nVkukuZhTXGhj10+JCW8yDNSXSGGd3O3ysfIKKxvEzUdrWpjFZdslaLdWD1xx\nWcomLtdwvFU15Hz5W0Dg/YXX/+4ZYMiBGxbgGvBmErxA2a0C9jp/P0YhZW+M\nDxZHsuPzW6ko9X9WYX8et9jEKhd4jLetLbbrhysgIndxxAsC8j7ugU8HDQcr\nZavqdIwjWIRYd++kdsi8QjLgk0pfHNRtorCpJ+l2SqyYadL4DPoqrGZ6qgjg\nm87TAGqizBVHKkhg6tmk+LcTWFR+jhJD3d2Xqw4JLbZi0FZ8XqQZ9XG0jmDZ\nVKGK\r\n=wo3j\r\n-----END PGP SIGNATURE-----\r\n","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIQCiDcUPgBpxI+p3O+0kE6Kx6kZT32HrHLis7o8yRo3lXwIgZ6a74YwLHxRoq1J19zhYEZcwZadqV8uVaczIfOAPHPM="}],"size":3454,"noattachment":false,"key":"/@node-rs/helper/-/@node-rs/helper-0.4.0.tgz"},"maintainers":[{"name":"broooooklyn","email":"lynweklm@gmail.com"}],"_npmUser":{"name":"broooooklyn","email":"lynweklm@gmail.com"},"directories":{},"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/helper_0.4.0_1599236850239_0.08536777422759645"},"_hasShrinkwrap":false,"readme":"# `@node-rs/helper`\n\n[![install size](https://packagephobia.com/badge?p=@node-rs/helper)](https://packagephobia.com/result?p=@node-rs/helper)\n[![Downloads](https://img.shields.io/npm/dm/@node-rs/helper.svg?sanitize=true)](https://npmcharts.com/compare/@node-rs/helper?minimal=true)\n\n> Helper library for load native package.\n\n## Usage\n\n### locateBinding\n\nLoad native binding file from `dirname`\n\n```ts\nloadBinding(dirname: string, filename?: string = 'index', packageName?: string): string\n```\n\n- `dirname`, dirname which the **.node** binding file located\n- `filename`, the `napi.name` filed in you `package.json`\n- `packageName`, the `name` filed in your `package.json`, `@swc/core` for example.\n\n- return native module\n\n```ts\nconst { loadBinding } = require('@node-rs/helper')\n\nmodule.exports = loadBinding(__dirname, 'swc', '@swc/core')\n```\n","publish_time":1599236850378,"_cnpm_publish_time":1599236850378,"dist-tags":{"alpha":"1.0.0-alpha.3","latest":"1.6.2"}}