{"bin":{"microbundle":"dist/cli.js"},"dist":{"shasum":"35434159cbabf07cccc44d1a0a49faeed05fa454","tarball":"https://registry.npmjs.org/microbundle/-/microbundle-0.12.0-next.5.tgz","fileCount":17,"integrity":"sha512-7JpnYl6AjLIkp/GHkupY+bGcnWaKx6gIhU45slBb4qVcI76MIWxLslpNImmnMPo2cDKpnLRWhFRUu9ahDQAJNw==","signatures":[{"sig":"MEUCIHefu+iaCahuUN/L5jjuSXIB35Nm0+odV15TdF+SoLQyAiEAjij1yO/k162pG6nxfwSWekuRtkdfnXI1GqrKlzYs99Q=","keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA"}],"unpackedSize":147567,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.4\r\nComment: https://openpgpjs.org\r\n\r\nwsFcBAEBCAAQBQJdYEGbCRA9TVsSAnZWagAAouoP/AkYnHIPd55wPzjuumCH\ndEyUfScbxaN13tphmWN/2A2DUq+Z5Vy5B+UG3zvs3KuCXjmXU7RoIVh3JfdX\nMzzHhdOjdAXP68sYCOc2U2XcY/ZI5PEPlBrWqGuZGOB+Y+0dBV5r0MdlZaNq\nE2o5yKPlggh7s+pRnGxjZgC3Dxsgem5vW+ViYezL/ib8Yz5gDVJ/wTbCksPx\nHOuCt5xjfWGmLOV2C/drXm7FXjHyxUiu1NjPmx/cZ+EC8MHcxVPKsJgH+jt9\ngckwj9Y76RaaJmqij0rV0LmQSL3Mv6RHEy649K4VGBledWrD1sRTyOEkarFe\n91ENcOzcKIwINaX84qHQZSeYX5V6iruNKn/CwoudABxTjQG0E1kaScTBTSam\nKV+yho1mdc2+XOFLmVwJPBJXVmuJhAnBbAe/4aqBwBAxzM4VuLqQwb8algr1\nsd0/WFuoxErUr55VrmhcejMzOMkQx+VET6s5OicMS5nCRqrfq/Up0WVnNhVg\ntiP/ltr9kT3rPAtSAP5eq5JWruEIYtUmtSPwnwFhpsHYkt2QjXdY/dBCD/HL\niBl9jOa5ibXFVQxGoBIwvVt0mag5avIZVyQ/areYTLmOIsGDt/rpFilHAhmS\n+pHgTQVsu2nbYEre/6ttjj1oEKEb5IYT/zvppEBD4Mmx/RpwgjyYy1c7IgPh\n/LPm\r\n=8rmQ\r\n-----END PGP SIGNATURE-----\r\n"},"jest":{"testURL":"http://localhost","testEnvironment":"node"},"main":"dist/microbundle.js","name":"microbundle","husky":{"hooks":{"pre-commit":"lint-staged"}},"author":{"url":"http://jasonformat.com","name":"Jason Miller","email":"jason@developit.ca"},"readme":"<p align=\"center\">\n  <img src=\"https://i.imgur.com/LMEgZMh.gif\" width=\"597\" alt=\"microbundle\">\n</p>\n<h1 align=\"center\">\n\tMicrobundle\n\t<a href=\"https://www.npmjs.org/package/microbundle\"><img src=\"https://img.shields.io/npm/v/microbundle.svg?style=flat\" alt=\"npm\"></a> <a href=\"https://travis-ci.org/developit/microbundle\"><img src=\"https://travis-ci.org/developit/microbundle.svg?branch=master\" alt=\"travis\"></a>\n</h1>\n<p align=\"center\">The <strong>zero-configuration</strong> bundler for <em>tiny modules</em>, powered by <a href=\"https://github.com/rollup/rollup\">Rollup</a>.</p>\n\n---\n\n## ✨ Features:\n\n- **One dependency** to bundle your library using only a `package.json`\n- Support for ESnext & async/await _(via [Bublé] & [async-to-promises])_\n- Produces tiny, optimized code for all inputs\n- Supports multiple entry modules _(`cli.js` + `index.js`, etc)_\n- Creates multiple output formats for each entry _(<abbr title=\"CommonJS (node)\">CJS</abbr>, <abbr title=\"Universal Module Definition\">UMD</abbr> & <abbr title=\"ECMAScript Modules\">ESM</abbr>)_\n- 0 configuration TypeScript support\n- Built-in Terser compression & gzipped bundle size tracking\n\n## 🔧 Installation\n\n### Download\n\n`npm i -D microbundle`\n\n### Set up your `package.json`\n\n```js\n{\n  \"source\": \"src/foo.js\",         // Your source file (same as 1st arg to microbundle)\n  \"main\": \"dist/foo.js\",        // output path for CommonJS/Node\n  \"module\": \"dist/foo.mjs\",     // output path for JS Modules\n  \"unpkg\": \"dist/foo.umd.js\",   // optional, for unpkg.com\n  \"scripts\": {\n    \"build\": \"microbundle\",       // uses \"source\" and \"main\" as input and output paths by default\n    \"dev\": \"microbundle watch\"\n  }\n}\n```\n\n### New: Modern JS\n\nMicrobundle now has a new `modern` format (`microbundle -f modern`).\nModern output still bundles and compresses your code, but it keeps useful syntax\naround that actually helps compression:\n\n```js\n// Our source, \"src/make-dom.js\":\nexport default async function makeDom(tag, props, children) {\n\tconst el = document.createElement(tag);\n\tel.append(...(await children));\n\treturn Object.assign(el, props);\n}\n```\n\nMicrobundle compiles the above to this:\n\n```js\nexport default async (e, t, a) => {\n\tconst n = document.createElement(e);\n\treturn n.append(...(await a)), Object.assign(n, t);\n};\n```\n\nThis is enabled by default - all you have to do is add the field to your `package.json`. You might choose to ship modern JS using the \"module\" field:\n\n```js\n{\n  \"main\": \"dist/foo.umd.js\",        // legacy UMD bundle (for Node & CDN's)\n  \"module\": \"dist/foo.modern.mjs\",  // modern ES2017 bundle\n  \"scripts\": {\n    \"build\": \"microbundle src/foo.js -f modern,umd\"\n  }\n}\n```\n\n## 📦 Usage\n\nMicrobundle includes two commands - `build` (the default) and `watch`. Neither require any options, but you can tailor things to suit your needs a bit if you like.\n\n### `microbundle` / `microbundle build`\n\nUnless overridden via the command line, microbundle uses the `source` property in your `package.json` to locate the input file, and the `main` property for the output.\n\nFor UMD builds, microbundle will use a snake case version of the `name` field in your `package.json` as export name. This can be overridden either by providing an `amdName` key in your `package.json` or via the `--name` flag in the cli.\n\n### `microbundle watch`\n\nActs just like `microbundle build`, but watches your source files and rebuilds on any change.\n\n### Using with TypeScript\n\nJust point the input to a `.ts` file through either the cli or the `source` key in your `package.json` and you’re done.\n\n### Specifying builds in `package.json`\n\nYou can specify output builds in a `package.json` as follows:\n\n```\n\"main\": \"dist/foo.js\",          // CJS bundle\n\"umd:main\": \"dist/foo.umd.js\",  // UMD bundle\n\"module\": \"dist/foo.m.js\",       // ES Modules bundle\n\"source\": \"src/foo.js\",         // custom entry module (same as 1st arg to microbundle)\n\"types\": \"dist/foo.d.ts\",       // TypeScript typings\n```\n\n### Mangling Properties\n\nLibraries often wish to rename internal object properties or class members to smaller names - transforming `this._internalIdValue` to `this._i`. Microbundle doesn't currently do this by default, but it can be enabled by adding a \"mangle\" property to your package.json, with a pattern to control when properties should be mangled. To mangle all property names beginning an underscore, add the following:\n\n```json\n{\n\t\"mangle\": {\n\t\t\"regex\": \"^_\"\n\t}\n}\n```\n\n### All CLI Options\n\n```\nUsage\n\t$ microbundle <command> [options]\n\nAvailable Commands\n\tbuild    Build once and exit\n\twatch    Rebuilds on any change\n\nFor more info, run any command with the `--help` flag\n\t$ microbundle build --help\n\t$ microbundle watch --help\n\nOptions\n\t-v, --version    Displays current version\n\t-i, --entry      Entry module(s)\n\t-o, --output     Directory to place build files into\n\t-f, --format     Only build specified formats  (default modern,es,cjs,umd)\n\t-w, --watch      Rebuilds on any change  (default false)\n\t--target         Specify your target environment (node or web)  (default web)\n\t--external       Specify external dependencies, or 'none'\n\t--globals        Specify globals dependencies, or 'none'\n\t--define         Replace constants with hard-coded values\n\t--alias          Map imports to different modules\n\t--compress       Compress output using Terser\n\t--strict         Enforce undefined global context and add \"use strict\"\n\t--name           Specify name exposed in UMD builds\n\t--cwd            Use an alternative working directory  (default .)\n\t--sourcemap      Generate source map  (default true)\n\t--raw            Show raw byte size  (default false)\n\t--jsx            A custom JSX pragma like React.createElement (default: h)\n\t--tsconfig       Specify the path to a custom tsconfig.json\n\t-h, --help       Displays this message\n\nExamples\n\t$ microbundle build --globals react=React,jquery=$\n\t$ microbundle build --define API_KEY=1234\n\t$ microbundle build --alias react=preact\n\t$ microbundle watch --no-sourcemap # don't generate sourcemaps\n\t$ microbundle build --tsconfig tsconfig.build.json\n```\n\n## 🛣 Roadmap\n\nHere's what's coming up for Microbundle:\n\n- [ ] [Multiple separate inputs->outputs](https://github.com/developit/microbundle/issues/50)\n- [x] [TypeScript support](https://github.com/developit/microbundle/issues/5)\n- [x] [Flowtype support](https://github.com/developit/microbundle/issues/5#issuecomment-351075881)\n\n## 🔨 Built with Microbundle\n\n- [Preact](https://github.com/preactjs/preact) Fast 3kB React alternative with the same modern API. Components & Virtual DOM.\n- [Stockroom](https://github.com/developit/stockroom) Offload your store management to a worker easily.\n- [Microenvi](https://github.com/fwilkerson/microenvi) Bundle, serve, and hot reload with one command.\n- [react-recomponent](https://github.com/philipp-spiess/react-recomponent) Reason-style reducer components for React using ES6 classes.\n- [brazilian-utils](https://github.com/brazilian-utils/brazilian-utils) Utils library for specific Brazilian businesses.\n- [react-hooks-lib](https://github.com/beizhedenglong/react-hooks-lib) A set of reusable react hooks.\n- [mdx-deck-live-code](https://github.com/JReinhold/mdx-deck-live-code) A library for [mdx-deck](https://github.com/jxnblk/mdx-deck) to do live React and JS coding directly in slides.\n- [react-router-ext](https://github.com/ri7nz/react-router-ext) An Extended [react-router-dom](https://github.com/ReactTraining/react-router/tree/master/packages/react-router-dom) with simple usage.\n- [routex.js](https://github.com/alexhoma/routex.js) A dynamic routing library for Next.js.\n\n## 🥂 License\n\n[MIT](https://oss.ninja/mit/developit/)\n\n[rollup]: https://github.com/rollup/rollup\n[bublé]: https://github.com/Rich-Harris/buble\n[async-to-promises]: https://github.com/rpetrich/babel-plugin-transform-async-to-promises\n","source":"src/index.js","license":"MIT","scripts":{"lint":"eslint src","test":"npm run -s lint && npm run -s build && cross-env BABEL_ENV=test jest","build":"npm run -s build:babel && npm run -s build:self","prepare":"npm run -s build","release":"npm run -s prepare && npm test && git commit -am $npm_package_version && git tag $npm_package_version && git push && git push --tags && npm publish","build:self":"node dist/cli.js --target=node --format cjs src/{cli,index}.js","build:babel":"babel-node src/cli.js --target=node --format cjs src/{cli,index}.js","prepare:babel":"babel src/*.js -d dist && npm t"},"_npmUser":{"name":"harmony","email":"npm.leah@hrmny.sh"},"keywords":["bundle","rollup","micro library"],"prettier":{"useTabs":true,"singleQuote":true,"trailingComma":"all"},"repository":{"url":"https://github.com/developit/microbundle.git","type":"git"},"description":"Zero-configuration bundler for tiny JS libs, powered by Rollup.","directories":{},"maintainers":[{"name":"developit","email":"jason@developit.ca"}],"dependencies":{"sade":"^1.6.1","kleur":"^3.0.3","tslib":"^1.10.0","rollup":"^1.19.4","asyncro":"^3.0.0","cssnano":"^4.1.10","filesize":"^4.1.2","camelcase":"^5.3.1","gzip-size":"^5.1.1","tiny-glob":"^0.2.6","typescript":"^3.5.3","@babel/core":"^7.5.5","brotli-size":"^4.0.0","autoprefixer":"^9.6.1","lodash.merge":"^4.6.2","pretty-bytes":"^5.3.0","es6-promisify":"^6.0.1","@babel/preset-env":"^7.5.5","rollup-plugin-es3":"^1.1.0","@babel/preset-flow":"^7.0.0","rollup-plugin-json":"^4.0.0","babel-plugin-macros":"^2.4.2","rollup-plugin-alias":"^2.0.0","rollup-plugin-babel":"^4.3.3","rollup-plugin-terser":"^5.1.1","rollup-plugin-postcss":"^2.0.3","rollup-plugin-commonjs":"^10.0.2","@babel/plugin-syntax-jsx":"^7.2.0","module-details-from-path":"^1.0.3","rollup-plugin-bundle-size":"^1.0.1","rollup-plugin-typescript2":"^0.23.0","rollup-plugin-node-resolve":"^5.2.0","@babel/plugin-transform-react-jsx":"^7.3.0","@babel/plugin-proposal-class-properties":"7.5.5","@babel/plugin-transform-flow-strip-types":"^7.4.4","babel-plugin-transform-async-to-promises":"^0.8.14","babel-plugin-transform-replace-expressions":"^0.2.0"},"_hasShrinkwrap":false,"readmeFilename":"README.md","devDependencies":{"esm":"^3.2.22","jest":"^24.8.0","husky":"^3.0.3","eslint":"^6.1.0","rimraf":"^3.0.0","fs-extra":"^8.1.0","prettier":"^1.18.2","cross-env":"^5.2.0","@babel/cli":"^7.5.5","babel-jest":"^24.8.0","strip-ansi":"^5.2.0","@babel/node":"^7.5.5","lint-staged":"^9.2.0","shell-quote":"^1.6.1","directory-tree":"^2.2.3","travis-size-report":"^1.1.0","regenerator-runtime":"^0.13.3","eslint-config-prettier":"^6.0.0","eslint-plugin-prettier":"^3.1.0","eslint-config-developit":"^1.1.1","@babel/plugin-proposal-throw-expressions":"^7.2.0"},"_npmOperationalInternal":{"tmp":"tmp/microbundle_0.12.0-next.5_1566589338629_0.6149984364226357","host":"s3://npm-registry-packages"},"_id":"microbundle@0.12.0-next.5","version":"0.12.0-next.5"}