{"_id":"@marijn/buildtool@1.2.1","dist":{"shasum":"d63fafa6b7dedd1bb1c5bde575cbfa1a9a0148cc","tarball":"http://registry-npm.ywwl.com/@marijn/buildtool/download/@marijn/buildtool-1.2.1.tgz","fileCount":7,"integrity":"sha512-CcbDNOPXiY5pW+YECfc5PuqXR9YvGRENlo8vVCNDo7AuJgKfo+DkEQk6emaqZy58TrVrKy+BCj+IErV0ZiPJnQ==","signatures":[{"sig":"MEUCIQCYkjdcZmwrIFcOKimiboigKIVsYa2X9pqoLGtP0RH4BgIgO1AWUvYWYRdpu/TQyFLB7cUf4fP3kQxMlfE4F5rlO2I=","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"},{"keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U","sig":"MEYCIQCH/gDFX4vqw6g+ANnMciei/kBe2hCJtIn4xvS/3eAbmwIhAIYm0PYoSYy7aIBAr1OA1EZOdRCSYKBKafwSWxPTaFXT"}],"unpackedSize":33664,"size":8618,"noattachment":false,"key":"/@marijn/buildtool/-/@marijn/buildtool-1.2.1.tgz"},"main":"./src/buildtool.js","name":"@marijn/buildtool","author":{"url":"http://marijnhaverbeke.nl","name":"Marijn Haverbeke","email":"marijn@haverbeke.berlin"},"gitHead":"4148c765eb1259bfdb29d8b8e5a7405dbaa725ba","license":"MIT","scripts":{"prepare":"tsc","build-readme":"builddocs --name buildtool --main src/README.md --format markdown src/*.ts > README.md"},"version":"1.2.1","_npmUser":{"name":"marijn","email":"marijn@haverbeke.berlin"},"repository":{"url":"git+https://code.haverbeke.berlin/marijn/buildtool.git","type":"git"},"_npmVersion":"11.19.0","description":"Tool for building TypeScript packages","directories":{},"maintainers":[{"name":"marijn","email":"marijn@haverbeke.berlin"}],"_nodeVersion":"24.21.0","dependencies":{"acorn":"^8.10.0","rollup":"^4.8.0","acorn-walk":"^8.2.0","typescript":"^5.3.3","@types/mocha":"^9.1.1","rollup-plugin-dts":"^6.1.0"},"_hasShrinkwrap":false,"devDependencies":{"builddocs":"^1.0.8","getdocs-ts":"^1.0.0","@types/node":"^20.0.0"},"_npmOperationalInternal":{"host":"s3://npm-registry-packages-npm-production","tmp":"tmp/buildtool_1.2.1_1790237263180_0.9102194335730664"},"readme":"# @marijn/buildtool\n\nUtility to build TypeScript projects that conform to a given set of\nconventions quickly and cleanly. Exports functions that wrap the\nTypeScript compiler and Rollup to build or watch one or more projects\nin one go, performing a single shared build (so that files from\ndifferent projects aren't compiled twice).\n\nAssumes your projects are set up like this:\n\n - TypeScript files in an `src` directory, will be compiled to\n   `dist/index.js` (ES module), `dist/index.cjs` (CommonJS), and\n   `dist/index.d.ts` (TypeScript) files.\n\n - Tests, if any, under `test`, will be compiled in-place to `.js`\n   files, which are ES modules.\n\n - Doc comments prefixed with triple slash `///` syntax will be\n   converted to `/**` JSDoc comments in the output, so that TypeScript\n   tooling picks them up.\n\n## API\n\n * **`build`**`(main: string | readonly string[], options?: BuildOptions = {}) → Promise`\\\n   Build the package with main entry point `main`, or the set of\n   packages with the given entry point files. Output files will be\n   written to the `dist` directory one level up from the entry file.\n   Any TypeScript files in a `test` directory one level up from main\n   files will be built in-place.\n\n\n * **`watch`**`(mains: readonly string[], extra?: readonly string[] = [], options?: BuildOptions = {})`\\\n   Build the given packages, along with an optional set of extra\n   files, and keep rebuilding them every time an input file changes.\n\n\n### interface BuildOptions\n\nOptions passed to `build` or `watch`.\n\n * **`typeCheck`**`?: boolean`\\\n   Fail the build on type errors. defaults to false\n\n * **`sourceMap`**`?: boolean`\\\n   Generate sourcemap when generating bundle. defaults to false\n\n * **`tsOptions`**`?: any`\\\n   Additional compiler options to pass to TypeScript.\n\n * **`bundleName`**`?: string`\\\n   Base filename to use for the output bundle and declaration\n   files. Defaults to `\"index\"`.\n\n * **`expandLink`**`?: fn(anchor: string) → string | null`\\\n   When given, this is used to convert anchor links in the `///`\n   comments to full URLs.\n\n * **`expandRootLink`**`?: string`\\\n   When given, prefix this to links in the comments that start with\n   a `/`.\n\n * **`outputPlugin`**`?: fn(root: string) → Plugin | Promise`\\\n   Adds a Rollup output plugin to use.\n\n * **`cjsOutputPlugin`**`?: fn(root: string) → Plugin`\\\n   Adds an output plugin to use only for CommonJS bundles.\n\n * **`pureTopCalls`**`?: boolean`\\\n   When set to true, add a `/*@__PURE__*/` comment before top level\n   function calls, so that tree shakers will consider them pure.\n   Note that this can break your code if it makes top-level\n   function calls that have side effects.\n\n * **`onRebuildStart`**`?: fn(packages: readonly string[])`\\\n   Function to call when starting a rebuild via `watch`, passing\n   the root directories of the packages that are being built. The\n   default is to just log the base names of the directories.\n\n * **`onRebuildEnd`**`?: fn(packages: readonly string[])`\\\n   Function to call when finishing a rebuild.\n\n\n## Community\n\nThis is open source software released under an\n[MIT license](https://code.haverbeke.berlin/marijn/buildtool/src/branch/main/LICENSE).\n\nDevelopment happens on\n[Forgejo](https://code.haverbeke.berlin/marijn/buildtool). Use the [bug\ntracker](https://code.haverbeke.berlin/marijn/buildtool/issues) to report\nproblems.\n\n","publish_time":1790237263316,"_cnpm_publish_time":1790237263316,"dist-tags":{"latest":"1.2.1"}}