{"_id":"@0q/atlas-local","name":"@0q/atlas-local","dist-tags":{"latest":"0.0.3"},"versions":{"0.0.3":{"name":"@0q/atlas-local","version":"0.0.3","description":"Template project for writing node package with napi-rs","main":"index.js","repository":{"type":"git","url":"git+ssh://git@github.com/jeroenvervaeke/atlas-local-sdk.git"},"license":"MIT","keywords":["napi-rs","NAPI","N-API","Rust","node-addon","node-addon-api"],"napi":{"binaryName":"atlas-local-sdk","targets":["x86_64-pc-windows-msvc","x86_64-apple-darwin","x86_64-unknown-linux-gnu","aarch64-apple-darwin"]},"engines":{"node":">= 6.14.2 < 7 || >= 8.11.2 < 9 || >= 9.11.0 < 10 || >= 10.0.0"},"publishConfig":{"registry":"https://registry.npmjs.org/","access":"public"},"scripts":{"artifacts":"napi artifacts","build":"napi build --platform --release","build:debug":"napi build --platform","format":"run-p format:prettier format:rs format:toml","format:prettier":"prettier . -w","format:toml":"taplo format","format:rs":"cargo fmt","lint":"oxlint .","prepublishOnly":"napi prepublish -t npm","test":"ava","version":"napi version","prepare":"husky"},"devDependencies":{"@emnapi/core":"^1.4.5","@emnapi/runtime":"^1.4.5","@napi-rs/cli":"^3.0.3","@oxc-node/core":"^0.0.30","@taplo/cli":"^0.7.0","@tybys/wasm-util":"^0.10.0","ava":"^6.4.1","chalk":"^5.4.1","husky":"^9.1.7","lint-staged":"^16.1.2","npm-run-all2":"^8.0.4","oxlint":"^1.8.0","prettier":"^3.6.2","tinybench":"^4.0.1","typescript":"^5.8.3"},"lint-staged":{"*.@(js|ts|tsx)":["oxlint --fix"],"*.@(js|ts|tsx|yml|yaml|md|json)":["prettier --write"],"*.toml":["taplo format"]},"ava":{"extensions":{"ts":"module"},"timeout":"2m","workerThreads":false,"environmentVariables":{"OXC_TSCONFIG_PATH":"./__test__/tsconfig.json"},"nodeArguments":["--import","@oxc-node/core/register"]},"prettier":{"printWidth":120,"semi":false,"trailingComma":"all","singleQuote":true,"arrowParens":"always"},"packageManager":"yarn@4.9.2","optionalDependencies":{"@0q/atlas-local-win32-x64-msvc":"0.0.3","@0q/atlas-local-darwin-x64":"0.0.3","@0q/atlas-local-linux-x64-gnu":"0.0.3","@0q/atlas-local-darwin-arm64":"0.0.3"},"_id":"@0q/atlas-local@0.0.3","gitHead":"f3630a38d555ad176286d26a81006f6a6926d067","types":"./index.d.ts","bugs":{"url":"https://github.com/jeroenvervaeke/atlas-local-sdk/issues"},"homepage":"https://github.com/jeroenvervaeke/atlas-local-sdk#readme","_nodeVersion":"22.17.1","_npmVersion":"10.9.2","dist":{"integrity":"sha512-vIS2ITGmzxHt8cC2f5UUXEh3P9IKE4MWj2AlFHWjCCHxYlc34z4ZGgKNnHV7XFvku99SLDm7KBeB1kRtnYYTyw==","shasum":"23da10955b778bb86eb2efab260fc11fb24bb541","tarball":"https://registry.npmjs.org/@0q/atlas-local/-/atlas-local-0.0.3.tgz","fileCount":5,"unpackedSize":17824,"attestations":{"url":"https://registry.npmjs.org/-/npm/v1/attestations/@0q%2fatlas-local@0.0.3","provenance":{"predicateType":"https://slsa.dev/provenance/v1"}},"signatures":[{"keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U","sig":"MEUCIQCn6kbNJjVllssPspbsIlgyfbuimdIyHIy5F3Hvd+DudQIgFc+vz6eHTzAoXTgYI/g37qfFCzou8wSl9BXVOG9Gc5w="}]},"_npmUser":{"name":"0q","email":"npmjs.2itdt@0q.is"},"directories":{},"maintainers":[{"name":"0q","email":"npmjs.2itdt@0q.is"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages-npm-production","tmp":"tmp/atlas-local_0.0.3_1754396888914_0.45902377052851984"},"_hasShrinkwrap":false}},"time":{"created":"2025-08-05T12:28:08.831Z","0.0.3":"2025-08-05T12:28:09.171Z","modified":"2025-08-05T12:28:09.656Z"},"maintainers":[{"name":"0q","email":"npmjs.2itdt@0q.is"}],"description":"Template project for writing node package with napi-rs","homepage":"https://github.com/jeroenvervaeke/atlas-local-sdk#readme","keywords":["napi-rs","NAPI","N-API","Rust","node-addon","node-addon-api"],"repository":{"type":"git","url":"git+ssh://git@github.com/jeroenvervaeke/atlas-local-sdk.git"},"bugs":{"url":"https://github.com/jeroenvervaeke/atlas-local-sdk/issues"},"license":"MIT","readme":"# `@napi-rs/package-template`\n\n![https://github.com/napi-rs/package-template/actions](https://github.com/napi-rs/package-template/workflows/CI/badge.svg)\n\n> Template project for writing node packages with napi-rs.\n\n# Usage\n\n1. Click **Use this template**.\n2. **Clone** your project.\n3. Run `yarn install` to install dependencies.\n4. Run `yarn napi rename -n [@your-scope/package-name] -b [binary-name]` command under the project folder to rename your package.\n\n## Install this test package\n\n```\nyarn add @napi-rs/package-template\n```\n\n## Ability\n\n### Build\n\nAfter `yarn build/npm run build` command, you can see `package-template.[darwin|win32|linux].node` file in project root. This is the native addon built from [lib.rs](./src/lib.rs).\n\n### Test\n\nWith [ava](https://github.com/avajs/ava), run `yarn test/npm run test` to testing native addon. You can also switch to another testing framework if you want.\n\n### CI\n\nWith GitHub Actions, each commit and pull request will be built and tested automatically in [`node@20`, `@node22`] x [`macOS`, `Linux`, `Windows`] matrix. You will never be afraid of the native addon broken in these platforms.\n\n### Release\n\nRelease native package is very difficult in old days. Native packages may ask developers who use it to install `build toolchain` like `gcc/llvm`, `node-gyp` or something more.\n\nWith `GitHub actions`, we can easily prebuild a `binary` for major platforms. And with `N-API`, we should never be afraid of **ABI Compatible**.\n\nThe other problem is how to deliver prebuild `binary` to users. Downloading it in `postinstall` script is a common way that most packages do it right now. The problem with this solution is it introduced many other packages to download binary that has not been used by `runtime codes`. The other problem is some users may not easily download the binary from `GitHub/CDN` if they are behind a private network (But in most cases, they have a private NPM mirror).\n\nIn this package, we choose a better way to solve this problem. We release different `npm packages` for different platforms. And add it to `optionalDependencies` before releasing the `Major` package to npm.\n\n`NPM` will choose which native package should download from `registry` automatically. You can see [npm](./npm) dir for details. And you can also run `yarn add @napi-rs/package-template` to see how it works.\n\n## Develop requirements\n\n- Install the latest `Rust`\n- Install `Node.js@10+` which fully supported `Node-API`\n- Install `yarn@1.x`\n\n## Test in local\n\n- yarn\n- yarn build\n- yarn test\n\nAnd you will see:\n\n```bash\n$ ava --verbose\n\n  ✔ sync function from native code\n  ✔ sleep function from native code (201ms)\n  ─\n\n  2 tests passed\n✨  Done in 1.12s.\n```\n\n## Release package\n\nEnsure you have set your **NPM_TOKEN** in the `GitHub` project setting.\n\nIn `Settings -> Secrets`, add **NPM_TOKEN** into it.\n\nWhen you want to release the package:\n\n```\nnpm version [<newversion> | major | minor | patch | premajor | preminor | prepatch | prerelease [--preid=<prerelease-id>] | from-git]\n\ngit push\n```\n\nGitHub actions will do the rest job for you.\n","readmeFilename":"README.md","_rev":"1-a65cbbff2e8bdbbcaaf82f7861bdb953"}