{"name":"@node-rs/helper","version":"0.2.1","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.0"},"gitHead":"87069a906b5b086d8c94d0928534eea562819233","_id":"@node-rs/helper@0.2.1","_nodeVersion":"12.18.2","_npmVersion":"lerna/3.22.1/node@v12.18.2+x64 (linux)","dist":{"integrity":"sha512-DEPYwfkkhJlVLFu6hWVGZi96jUCBahi1WoHZAC7gSFoeoJtxwJ+FrJSDx/8c9aIwAf477NnKj8bRJzFm98Me3A==","shasum":"6bbd9023301a68a2717111e99c41ef38e3fa0726","tarball":"http://registry-npm.ywwl.com/@node-rs/helper/download/@node-rs/helper-0.2.1.tgz","fileCount":7,"unpackedSize":5245,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.4\r\nComment: https://openpgpjs.org\r\n\r\nwsFcBAEBCAAQBQJfE++HCRA9TVsSAnZWagAAqMIP+gN7FOKOQmVXB08ahIbw\noAt08JfZQxzXgPhvThp/plrrh0VI40sGebKBF/Wc6kOMqesVkTVtYjaV6hGn\nfdc630S/BcS4l9EDuQVSCBkuGr8whHgutOnk7XYAnYzDe3HbUlalSSYbqmHr\niiuS8APcDYA90PBGJrKUX46EZqGsYjzVQezPQR+Wa1oUzu6U9DlmOrwBlbhy\n02TsNSOYyTMhVzffVuyoEAeGVd+PQIZ6DABSckjW/yMkiREMEbxktVLqVCTe\nSUZZyJ1wyUcMmy/1k1/6sY2m9YmINR0WeVOc63c4Cl3xEirfzGcFn8aW6dgb\naBD69TnOp45uz/53CtJsVecLvwztjITYHZhS4xFm9xNNX0SAsrOvaAt+2mSQ\nbTOucowb/CiNE/D6kEURbb2AMIQ9K6DaRYlUwykGpUyrBO94ddFYWTw3Y7+d\n14ZHuKbiRL3tZiEAA/bQzcBMNry4IdNBAPzkMIwcuCQfFFw9TY/L08Evs++7\naUsrDehGRF7pnH9J8tFXZGKGQg/3i8WBUQWuoQojz56VZOxs4RzJyYqRY5zA\nH0fvBtwho9xie3aDujm61smk5Y0sbeNqOa2QP8k+a9vq32VwmG9PlkF3nRhf\n6ix1s/8tkqz3Lo2KYCCFkGzikSjaftDwTkI8MuI2bkujMNz3oQNPQNWtAAuL\n1VtE\r\n=SzH7\r\n-----END PGP SIGNATURE-----\r\n","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEQCIG4m0/yxctbgGuM8DI7V+JCtNiLiNvo4xNfnz8tMsBkaAiAyaOc55FyCXoFbjdkaFYlS2Rf8PDARir7AuqTgtxVUhw=="}],"size":2753,"noattachment":false,"key":"/@node-rs/helper/-/@node-rs/helper-0.2.1.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.2.1_1595142022683_0.7119090620010382"},"_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":1595142022848,"_cnpm_publish_time":1595142022848,"dist-tags":{"alpha":"1.0.0-alpha.3","latest":"1.6.2"}}