Jest runner for Rollup, plays very very nicely in monorepo scenarios
Please consider following this project's author, Charlike Mike Reagent, and ⭐️ the project to show your ❤️ and support.
If you have any how-to kind of questions, please read the Contributing Guide and Code of Conduct documents. For bugs reports and feature requests, please create an issue or ping @tunnckoCore at Twitter.
|Any legal or licensing questions, like private or commerical use|
|For any critical problems and security reports|
|Consulting, professional support, personal or team training|
|For any questions about Open Source, partnerships and sponsoring|
Table of Contents
$ yarn add jest-runner-rollup
First, put it in your Jest config
moduleexports =rootDir: __dirnamedisplayName: 'bundle'testMatch:// if there is no extension, it try to autodetect it.'<rootDir>/packages/*/src/index'moduleFileExtensions: 'js' 'jsx' 'ts' 'tsx' 'mjs'runner: 'jest-runner-rollup';
Then, write Rollup config file. It automatically detects your
If you want you also can name it
put your config in
jest-runner.config.js (this config file can be used for other jest runners too), like so
moduleexports =rollup:plugins:/*commonjs(),nodeResolve()*/output:preferConst: true format: 'cjs' exports: 'named'preferConst: true format: 'esm';
By default, the bundle file will be
dist/<format>/index.js, even if only one output format is given.
If you want to change that behavior, you can pass
Guides and Community
For bug reports and feature requests, please join our community forum and open a thread there with prefixing the title of the thread with the name of the project if there's no separate channel for it.
Consider reading the Support and Release Policy guide if you are interested in what are the supported Node.js versions and how we proceed. In short, we support latest two even-numbered Node.js release lines.
Support the project
Become a Partner or Sponsor? 💵 Check the Partner, Sponsor or Omega-level tiers! 🎉 You can get your company logo, link & name on this file. It's also rendered on package page in npmjs.com and yarnpkg.com sites too! 🚀
Thanks to the hard work of these wonderful people this project is alive! It follows the all-contributors specification. Don't hesitate to add yourself to that list if you have made any contribution! ;) See how, here.
Charlike Mike Reagent
💻 📖 💬 👀 🔍
Consider showing your support to them. 💖