Skip to content

Commit

Permalink
Merge 4c625d6 into 394a4ae
Browse files Browse the repository at this point in the history
  • Loading branch information
NaridaL committed May 24, 2020
2 parents 394a4ae + 4c625d6 commit 1135bd2
Show file tree
Hide file tree
Showing 2 changed files with 26 additions and 2 deletions.
4 changes: 2 additions & 2 deletions package.json
Expand Up @@ -3,14 +3,14 @@
"version": "5.6.0",
"description": "Utility functions and common patterns for MobX",
"main": "mobx-utils.umd.js",
"module": "lib/mobx-utils.js",
"module": "mobx-utils.module.js",
"jsnext:main": "mobx-utils.module.js",
"react-native": "mobx-utils.module.js",
"typings": "lib/mobx-utils.d.ts",
"sideEffects": false,
"scripts": {
"prettier": "prettier --write \"**/*.js\" \"**/*.jsx\" \"**/*.tsx\" \"**/*.ts\"",
"build": "tsc -p src && rollup lib/mobx-utils.js -e mobx -g mobx:mobx -o mobx-utils.umd.js -f umd --name mobxUtils && rollup lib/mobx-utils.js -e mobx -o mobx-utils.module.js -f es",
"build": "tsc -p src && rollup -c",
"watch": "jest --watch",
"test": "jest",
"prepublishOnly": "npm run build && npm run build-docs",
Expand Down
24 changes: 24 additions & 0 deletions rollup.config.js
@@ -0,0 +1,24 @@
export default {
input: "lib/mobx-utils.js",
output: [
{
format: "umd",
file: "mobx-utils.umd.js",
name: "mobxUtils",
globals: {
mobx: "mobx",
},
},
{
format: "es",
file: "mobx-utils.module.js",
},
],
external: ["mobx"],
onwarn: function (warning, warn) {
// https://github.com/rollup/rollup/wiki/Troubleshooting#this-is-undefined
if ("THIS_IS_UNDEFINED" === warning.code) return

warn(warning)
},
}

0 comments on commit 1135bd2

Please sign in to comment.