Socket
Socket
Sign inDemoInstall

mobx-react

Package Overview
Dependencies
Maintainers
4
Versions
144
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

mobx-react - npm Package Compare versions

Comparing version 7.0.0 to 7.0.1

src/disposeOnUnmount.ts

229

CHANGELOG.md

@@ -1,25 +0,44 @@

# MobX-React Changelog
# mobx-react
### 6.3.0
## 7.0.1
- Updated mobx-react-lite to 2.2.0 which removes the need to manually configure batching. Fixes [#859](https://github.com/mobxjs/mobx-react/issues/859)
### Patch Changes
### 6.2.4
- [`81a2f865`](https://github.com/mobxjs/mobx/commit/81a2f8654d9656e2e831176e45cbf926fbc364e0) Thanks [@FredyC](https://github.com/FredyC)! - ESM bundles without NODE_ENV present are available in dist folder. This useful for consumption in browser environment that supports ESM Choose either `esm.production.min.js` or `esm.development.js` from `dist` folder.
- Fix error thrown in the already defined observer class component warning message when attempting to get the components display name. [#887](https://github.com/mobxjs/mobx-react/issues/887)
- Updated dependencies [[`81a2f865`](https://github.com/mobxjs/mobx/commit/81a2f8654d9656e2e831176e45cbf926fbc364e0)]:
- mobx-react-lite@3.1.1
### 6.2.3
## 7.0.0
- Log warning if class component is already an observer to prevent memory leaks. [#839](https://github.com/mobxjs/mobx-react/issues/839)
- Fix disposeOnUnmount when using react-hot-loader. [#725](https://github.com/mobxjs/mobx-react/issues/725)
Release for compatibility with MobX v6
### 6.2.2
## 6.3.1
### Patch Changes
- [`aa780c0`](https://github.com/mobxjs/mobx-react/commit/aa780c07162be99e198e7bbdbd6465c1f451f1d6) [#908](https://github.com/mobxjs/mobx-react/pull/908) Thanks [@FredyC](https://github.com/FredyC)! - Initial setup of [changesets](https://github.com/atlassian/changesets). No code changes present.
## 6.3.0
- Updated mobx-react-lite to 2.2.0 which removes the need to manually configure batching. Fixes [#859](https://github.com/mobxjs/mobx-react/issues/859)
## 6.2.4
- Fix error thrown in the already defined observer class component warning message when attempting to get the components display name. [#887](https://github.com/mobxjs/mobx-react/issues/887)
## 6.2.3
- Log warning if class component is already an observer to prevent memory leaks. [#839](https://github.com/mobxjs/mobx-react/issues/839)
- Fix disposeOnUnmount when using react-hot-loader. [#725](https://github.com/mobxjs/mobx-react/issues/725)
## 6.2.2
- Observer batching imports are kept in production builds as side effects ([see issue](https://github.com/mobxjs/mobx-react-lite/issues/273))
### 6.2.1
## 6.2.1
- Remove auto configured observer batching using react-dom. Fixes: [#852](https://github.com/mobxjs/mobx-react/issues/852).
### 6.2.0
## 6.2.0

@@ -30,3 +49,3 @@ - Updated to latest mobx-react-lite V2 for compatibility with `React.StrictMode`.

### 6.1.6 / 6.1.7
## 6.1.6 / 6.1.7

@@ -36,3 +55,3 @@ - Fix an issue with class components & observableRequiresReaction. [#806](https://github.com/mobxjs/mobx-react/issues/806) through [#829](https://github.com/mobxjs/mobx-react/pull/829)

### 6.1.5
## 6.1.5

@@ -42,7 +61,7 @@ - Added check if `process.env` is available, fixes [#801](https://github.com/mobxjs/mobx-react/issues/801) through [#812](https://github.com/mobxjs/mobx-react/pull/812) by [@ynejati](https://github.com/ynejati)

### 6.1.4
## 6.1.4
- Update dependency mobx-react-lite@1.4.2 which includes fix for [RN Fast Refresh](https://github.com/mobxjs/mobx-react-lite/issues/226)
### 6.1.2 / 6.1.3
## 6.1.2 / 6.1.3

@@ -55,7 +74,7 @@ - Add reexport of `useObserver` from `mobx-react-lite` [#734](https://github.com/mobxjs/mobx-react/issues/734)

### 6.1.1
## 6.1.1
- Fixed issue where combining `@disposeOnUnmount` with `disposeOnUnmount` didn't clean up everything. Fixes [#666](https://github.com/mobxjs/mobx-react/issues/666) trough [#671](https://github.com/mobxjs/mobx-react/pull/671) by [@JabX](https://github.com/JabX)
### 6.1.0
## 6.1.0

@@ -69,7 +88,7 @@ - Restored the classic implementation of `observer`: class based components are patched again, rather than wrapping them in `<Observer>`, see [#703](https://github.com/mobxjs/mobx-react/pull/703). Fixes:

### 6.0.4
## 6.0.4
- Fixed IE 11 compatibility which was accidentally broken. Fixes [#698](https://github.com/mobxjs/mobx-react/issues/698)
### 6.0.3
## 6.0.3

@@ -79,7 +98,7 @@ - `disposeOnUnmount` now supports initializing it with an array of disposers. Fixes [#637](https://github.com/mobxjs/mobx-react/pull/637) through [#641](https://github.com/mobxjs/mobx-react/pull/641) by [@Amareis](https://github.com/Amareis)

### 6.0.2
## 6.0.2
- Added missing types for `MobXProviderContext`, `useLocalStore` and `useAsObservableSource`. Fixes #679.
### 6.0.0
## 6.0.0

@@ -115,35 +134,35 @@ **Breaking changes**

### 5.4.3
## 5.4.3
- Fixed [#612](https://github.com/mobxjs/mobx-react/issues/612), `contextType` was hoisted by `inject`, which shouldn't the case.
### 5.4.1 / 5.4.2
## 5.4.1 / 5.4.2
- Fixed issue where `react-is` wasn't properly rolled-up into the package. Fixes [#608](https://github.com/mobxjs/mobx-react/issues/608)
### 5.4.0
## 5.4.0
- Added support for forward refs, fixes [#602](https://github.com/mobxjs/mobx-react/issues/602)
### 5.3.6
## 5.3.6
- Fixed some additional issues around life-cycle patching, take 3. See [#536](https://github.com/mobxjs/mobx-react/pull/586) by [@xaviergonz](https://github.com/xaviergonz). Fixed [#579](https://github.com/mobxjs/mobx-react/issues/579)
### 5.3.5
## 5.3.5
- Fixed some additional issues around life-cycle patching, see [#583](https://github.com/mobxjs/mobx-react/pull/583) by [@xaviergonz](https://github.com/xaviergonz). Fixed [#581](https://github.com/mobxjs/mobx-react/issues/581)
### 5.3.4
## 5.3.4
- Fixed unending recursing as a result of lifecylce patching. Fixes [#579](https://github.com/mobxjs/mobx-react/issues/579) through [#582](https://github.com/mobxjs/mobx-react/pull/582) by [@xaviergonz](https://github.com/xaviergonz)
### 5.3.3
## 5.3.3
- Fixed `Cannot read property 'forEach' of undefined` exception if `disposeOnUnmount` was called conditionally. [#578](https://github.com/mobxjs/mobx-react/pull/578) by [Jef Hellemans](https://github.com/JefHellemans)
### 5.3.2
## 5.3.2
- Fixed: "process not defined", [#574](https://github.com/mobxjs/mobx-react/pull/574/) through [#576](https://github.com/mobxjs/mobx-react/pull/576/) by [@xaviergonz](https://github.com/xaviergonz)
### 5.3.0 / 5.3.1
## 5.3.0 / 5.3.1

@@ -155,31 +174,31 @@ _5.3.0 was retracted as files were not generated correctly during publish_

### 5.2.8
## 5.2.8
- Make sure `mobx-react` doesn't require `Object.assign` polyfill
### 5.2.7
## 5.2.7
- Fixed issue where React 16.5 printed a warning when using `Provider`, fixes [#545](https://github.com/mobxjs/mobx-react/issues/545)
### 5.2.6
## 5.2.6
- Fixed bug in defining properties (although the bug had no known observable effect). Fixes [#540](https://github.com/mobxjs/mobx-react/issues/540)
### 5.2.4 / 5.2.5
## 5.2.4 / 5.2.5
- Improved compatibility with React-Hot-Loader, see [#522](https://github.com/mobxjs/mobx-react/pull/522) by [theKashey](https://github.com/theKashey). Fixes [#500](https://github.com/mobxjs/mobx-react/issues/500)
### 5.2.3
## 5.2.3
- Fixed problem with `Symbol` feature detection. By [@Strate](https://github.com/Strate) through [#501](https://github.com/mobxjs/mobx-react/pull/501). Fixes [#498](https://github.com/mobxjs/mobx-react/issues/498) and [#503](https://github.com/mobxjs/mobx-react/issues/503).
### 5.2.2
## 5.2.2
- Polyfill `Symbol` if it doesn't exist. By [@Strate](https://github.com/Strate) through [#499](https://github.com/mobxjs/mobx-react/pull/499).
### 5.2.1
## 5.2.1
- Component `props` and `state` properties are now made observable during the instance creation. This restores the behavior from before 5.1.0 where `props` and `state` could safely be observed during mount. Actually it is now possible to do similar things in constructors as well. Fixes [#478](https://github.com/mobxjs/mobx-react/issues/478). Thanks [@Strate](https://github.com/Strate) for the idea and PR! [#496](https://github.com/mobxjs/mobx-react/pull/496).
### 5.2.0
## 5.2.0

@@ -190,7 +209,7 @@ - Added backward compatible support for MobX 5.

### 5.1.2
## 5.1.2
- Fixed regression bug in integration with devtools. Fixed through [#465](https://github.com/mobxjs/mobx-react/pull/465) by @le0nik
### 5.1.0
## 5.1.0

@@ -204,19 +223,19 @@ - Added support for React 16.3, including support for the `getDerivedStateFromProps` life-cycle hook. MobX will no longer use `componentWillMount` hook internally, so that it can be used in `StrictMode` react as well. Fixes [#447](https://github.com/mobxjs/mobx-react/issues/447)

### 5.0.0
## 5.0.0
- Added compatibility with MobX 4.x. This version is not compatible with older Mobx versions
### 4.4.3
## 4.4.3
- The exposed React Native build now uses commonjs, to prevent the need of further transpilation. Fixes [#428](https://github.com/mobxjs/mobx-react/issues/428)
### 4.4.2
## 4.4.2
- Fixed issue with mobx-react not compiling on react-native due to the presence of a `.babelrc` file. Fixes [#415](https://github.com/mobxjs/mobx-react/issues/415) by [Ryan Rampersad](https://github.com/ryanmr) through [#416](https://github.com/mobxjs/mobx-react/pull/416)
### 4.4.1
## 4.4.1
- Fixed syntax error in 4.4.0 that escaped
### 4.4.0
## 4.4.0

@@ -229,15 +248,15 @@ - `Observer` now supports render props, `render` and `inject`. See the updated readme. By [ZiYingMai](https://github.com/Sunshine168) through [#403](https://github.com/mobxjs/mobx-react/pull/403)

### 4.3.5
## 4.3.5
Fixed some issues with the typescript typings. See for example #353
### 4.3.4
## 4.3.4
Improved typescript typings, including support for `strict` mode in TS 2.6. Fixes
### 4.3.3
## 4.3.3
Added support for React 16. (No changes)
### 4.3.2
## 4.3.2

@@ -248,13 +267,13 @@ Killed accidentally exposed default exports.

### 4.3.1
## 4.3.1
### 4.3.0 (unpublished)
## 4.3.0 (unpublished)
Improved module rollup setup, enabling better tree shaking. See #324 / #328
### 4.2.2
## 4.2.2
- Fixed check for stateless components, by @leader22, see #280
### 4.2.1
## 4.2.1

@@ -268,31 +287,31 @@ _Note: Due to pull / rebase issue the release commit is incorrect. This is the released [commit](https://github.com/mobxjs/mobx-react/commit/f1b3eefc5239cb451b317204fa8aad94b4dcfc2f)_

### 4.2.0
## 4.2.0
- Same as 4.2.1, but contained build issue and is unpublished
### 4.1.8
## 4.1.8
- Undid change introduced in 4.1.4 where the lifecycle hooks were protected, as this breaks react-hot-loader.... Fixes #231
### 4.1.7
## 4.1.7
- Added support for React 15.5 (no deprecation warnings) and 16.0 (no proptypes / createClass), by @andykog, see #238. Fixes #233, #237
### 4.1.5
## 4.1.5
- Improved typescript typings, fixes #223
### 4.1.4
## 4.1.4
- Made lifecycle hooks used by mobx-react read-only to make sure they are not accidentally overwritten in component instances. Fixes, #195, #202. Note that they can still be defined, just make sure to define them on the prototype (`componentWillMount() {}`) instead of the instance (`componentWillMount = () => {}`). Which is best practice anyway.
### 4.1.3
## 4.1.3
- Fixed `ReactDOM.findDOMNode` exception when using react-test-runner, #216
### 4.1.2
## 4.1.2
- Exceptions caught during render are now rethrown with proper stack, fixes #206
### 4.1.1
## 4.1.1

@@ -302,15 +321,15 @@ - Exposed `wrappedInstance` and `wrappedComponent` in typings

### 4.1.0
## 4.1.0
- Added support for MobX3. Note that using MobX3 changes the error semantics. If an `observer` component throws, it will no longer crash the app, but just log the exceptions instead.
### 4.0.4
## 4.0.4
- Introduced `suppressChangedStoreWarning` to optionally supresss change store warnings, by @dropfen, see #182, #183
### 4.0.3
## 4.0.3
- Fixed issue where userland componentWilMount was run before observer componentWillMount
### 4.0.2
## 4.0.2

@@ -320,3 +339,3 @@ - Fixed order of `inject` overloads, see #169

### 4.0.1
## 4.0.1

@@ -326,5 +345,5 @@ - Improved typings, by @timmolendijk, fixes #164, #166

### 4.0.0
## 4.0.0
#### `observer` now uses shallow comparision for all props _(Breaking change)_
### `observer` now uses shallow comparision for all props _(Breaking change)_

@@ -346,3 +365,3 @@ `observer` used to compare all properties shallow in the built-in _shouldComponentUpdate_, except when it received

#### `inject(fn)(component)` will now track `fn` as well
### `inject(fn)(component)` will now track `fn` as well

@@ -373,3 +392,3 @@ `inject(func)` is now reactive as well, that means that transformations in the selector function will be tracked, see [#111](https://github.com/mobxjs/mobx-react/issues/111)

#### `this.props` and `this.state` in React components are now observables as well
### `this.props` and `this.state` in React components are now observables as well

@@ -398,7 +417,7 @@ A common cause of confusion were cases like:

#### Better support for Server Side Rendering
### Better support for Server Side Rendering
Introduced `useStaticRendering(boolean)` to better support server-side rendering scenarios. See [#140](https://github.com/mobxjs/mobx-react/issues/140)
#### Introduced `Observer` as alternative syntax to the `observer` decorator.
### Introduced `Observer` as alternative syntax to the `observer` decorator.

@@ -415,3 +434,3 @@ _This feature is still experimental and might change in the next minor release, or be deprecated_

#### Using `observer` to inject stores is deprecated
### Using `observer` to inject stores is deprecated

@@ -435,3 +454,3 @@ The fact that `observer` could inject stores as well caused quite some confusion.

#### Other improvements
### Other improvements

@@ -448,19 +467,19 @@ - If `mobx` and `mobx-react` are used in combination, all reactions are run as part of React's batched updates. This minimizes the work of the reconciler, guarantees optimal rendering order of components (if the rendering was not triggered from within a React event). Tnx @gkaemmer for the suggestion.

### 3.5.9
## 3.5.9
- Print warning when `inject` and `observer` are used in the wrong order, see #146, by @delaetthomas
### 3.5.8
## 3.5.8
- Fixed issue where `props` where not passed properly to components in very rare cases. Also fixed #115
### 3.5.7
## 3.5.7
- Bundles are no longer minified, fixes #127
### 3.5.6
## 3.5.6
- Export `propTypes` as `PropTypes`, like React (@andykog, ##117)
### 3.5.5
## 3.5.5

@@ -470,3 +489,3 @@ - Removed `experimental` status of `inject` / `Provider`. Official feature now.

### 3.5.4
## 3.5.4

@@ -479,15 +498,15 @@ - Introduced `wrappedInstance` by @rossipedia on `inject` decorated HOC's, see https://github.com/mobxjs/mobx-react/pull/90/

### 3.5.3
## 3.5.3
- Fixed error `Cannot read property 'renderReporter' of undefined` (#96)
### 3.5.2
## 3.5.2
- Added propTypes.observableArrayOf and propTypes.arrayOrObservableArrayOf (#91)
### 3.5.1
## 3.5.1
- Fixed regression #85, changes caused by the constructor results in inconsistent rendering (N.B.: that is un-idiomatic React usage and React will warn about this!)
### 3.5.0
## 3.5.0

@@ -501,3 +520,3 @@ - Introduced `inject("store1", "store2")(component)` as alternative syntax to inject stores. Should address #77, #70

### 3.4.0
## 3.4.0

@@ -507,3 +526,3 @@ - Introduced `Provider` / context support (#53 / MobX #300)

### 3.3.1
## 3.3.1

@@ -513,11 +532,11 @@ - Added typescript typings form `mobx-react/native` and `mobx-react/custom`

### 3.3.0
## 3.3.0
- Upgraded to MobX 2.2.0
### 3.2.0
## 3.2.0
- Added support for react-native 0.25 and higher. By @danieldunderfelt.
### 3.1.0
## 3.1.0

@@ -528,7 +547,7 @@ - Added support for custom renderers (without DOM), use: `mobx-react/custom` as import fixes #42

### 3.0.5
## 3.0.5
Introduced `componentWillReact`
### 3.0.4
## 3.0.4

@@ -543,39 +562,39 @@ The debug name stateless function components of babel transpiled jsx are now properly picked up if the wrapper is applied after defining the component:

### 3.0.3
## 3.0.3
Removed peer dependencies, React 15 (and 0.13) are supported as well. By @bkniffler
### 3.0.2
## 3.0.2
Removed the warning introduced in 3.0.1. It triggered always when using shallow rendering (when using shallow rendering `componentDidMount` won't fire. See https://github.com/facebook/react/issues/4919).
### 3.0.1
## 3.0.1
Added warning when changing state in `getInitialState` / `constructor`.
### 3.0.0
## 3.0.0
Upgraded to MobX 2.0.0
### 2.1.5
## 2.1.5
Improved typescript typings overloads of `observer`
### 2.1.4
## 2.1.4
Added empty 'dependencies' section to package.json, fixes #26
### 2.1.3
## 2.1.3
Added support for context to stateless components. (by Kosta-Github).
### 2.1.1
## 2.1.1
Fixed #12: fixed React warning when a component was unmounted after scheduling a re-render but before executing it.
### 2.1.0
## 2.1.0
Upped dependency of mobx to 1.1.1.
### 2.0.1
## 2.0.1

@@ -602,15 +621,15 @@ It is now possible to define `propTypes` and `getDefaultProps` on a stateless component:

### 2.0.0
## 2.0.0
Use React 0.14 instead of React 0.13. For React 0.13, use version `mobx-react@1.0.2` or higher.
### 1.0.2
## 1.0.2
Minor fixes and improvements
### 1.0.1
## 1.0.1
Fixed issue with typescript typings. An example project with MobX, React, Typescript, TSX can be found here: https://github.com/mobxjs/mobx-react-typescript
### 1.0.0
## 1.0.0

@@ -617,0 +636,0 @@ `reactiveComponent` has been renamed to `observer`

{
"name": "mobx-react",
"version": "7.0.0",
"description": "React bindings for MobX. Create fully reactive components.",
"source": "src/index.ts",
"main": "dist/index.js",
"umd:main": "dist/mobxreact.umd.production.min.js",
"unpkg": "dist/mobxreact.umd.production.min.js",
"jsnext:main": "dist/mobxreact.esm.js",
"module": "dist/mobxreact.esm.js",
"react-native": "dist/mobxreact.esm.js",
"types": "dist/index.d.ts",
"sideEffects": [
"batching*"
],
"repository": {
"type": "git",
"url": "https://github.com/mobxjs/mobx-react.git"
},
"scripts": {
"test": "jest",
"watch": "jest --watch",
"lint": "eslint .",
"test:types": "yarn tsc --noEmit",
"test:check": "yarn test:types && yarn lint",
"test:ts": "tsc -p test",
"test:coverage": "jest -i --coverage",
"test:size": "size-limit",
"prettier": "prettier --write \"**/*.js\" \"**/*.ts\" \"**/*.tsx\"",
"release": "node publish.js",
"build": "tsdx build --name mobxReact --format cjs,esm,umd",
"postbuild": "yarn v6compat",
"v6compat": "shx cp dist/mobxreact.umd.production.min.js dist/mobx-react.umd.js"
},
"author": "Michel Weststrate",
"license": "MIT",
"bugs": {
"url": "https://github.com/mobxjs/mobx/issues"
},
"homepage": "https://mobxjs.github.io/mobx",
"resolutions": {
"@types/yargs": "12.0.1"
},
"peerDependencies": {
"mobx": "^6.0.0",
"react": "^16.8.0 || 16.9.0-alpha.0"
},
"devDependencies": {
"@babel/core": "^7.1.0",
"@babel/plugin-proposal-class-properties": "^7.1.0",
"@babel/plugin-proposal-decorators": "^7.1.0",
"@babel/plugin-transform-react-jsx": "^7.0.0",
"@babel/preset-env": "^7.1.0",
"@testing-library/jest-dom": "^5.1.1",
"@testing-library/react": "^9.4.0",
"@types/create-react-class": "^15.6.0",
"@types/jest": "^25.1.1",
"@types/node": "^10.0.0",
"@types/prop-types": "^15.5.2",
"@types/react": "^16.0.13",
"@types/react-dom": "^16.0.1",
"@typescript-eslint/eslint-plugin": "^2.12.0",
"@typescript-eslint/parser": "^2.12.0",
"babel-eslint": "^10.0.2",
"babel-jest": "^25.1.0",
"coveralls": "^3.0.3",
"eslint": "^6.1.0",
"eslint-config-prettier": "^6.0.0",
"eslint-plugin-prettier": "^3.1.0",
"eslint-plugin-react": "^7.14.3",
"husky": "^1.0.0",
"jest": "^25.1.0",
"jest-environment-jsdom": "^25.1.0",
"jest-mock-console": "^1.0.0",
"lint-staged": "^7.0.5",
"lodash": "^4.17.4",
"mobx": "^6.0.0",
"prettier": "^1.7.2",
"prop-types": "^15.7.2",
"react": "^16.9.0",
"react-dom": "^16.9.0",
"replace": "^1.1.0",
"request": "^2.83.0",
"shelljs": "^0.8.3",
"shx": "^0.3.2",
"size-limit": "^1.3.2",
"ts-jest": "^25.2.0",
"tsdx": "0.12.3",
"tslib": "1.10.0",
"typescript": "^3.7.0"
},
"dependencies": {
"mobx-react-lite": "^3.0.0"
},
"files": [
"dist",
"batching*"
],
"keywords": [
"mobx",
"mobservable",
"react-component",
"react",
"reactjs",
"reactive"
],
"lint-staged": {
"*.{ts,tsx,js}": [
"prettier --write",
"eslint --fix",
"git add"
]
},
"jest": {
"globals": {
"ts-jest": {
"tsConfig": "tsconfig.test.json"
}
"name": "mobx-react",
"version": "7.0.1",
"description": "React bindings for MobX. Create fully reactive components.",
"source": "src/index.ts",
"main": "dist/index.js",
"umd:main": "dist/mobxreact.umd.production.min.js",
"unpkg": "dist/mobxreact.umd.production.min.js",
"jsdelivr": "dist/mobxreact.umd.production.min.js",
"jsnext:main": "dist/mobxreact.esm.js",
"module": "dist/mobxreact.esm.js",
"react-native": "dist/mobxreact.esm.js",
"types": "dist/index.d.ts",
"typings": "dist/index.d.ts",
"files": [
"src",
"dist",
"LICENSE",
"CHANGELOG.md",
"README.md",
"batching*"
],
"sideEffects": false,
"repository": {
"type": "git",
"url": "https://github.com/mobxjs/mobx.git"
},
"transform": {
"^.+\\.tsx?$": "ts-jest",
"^.+\\.jsx?$": "babel-jest"
"author": "Michel Weststrate",
"license": "MIT",
"funding": {
"type": "opencollective",
"url": "https://opencollective.com/mobx"
},
"moduleFileExtensions": [
"ts",
"tsx",
"js",
"jsx",
"json"
"bugs": {
"url": "https://github.com/mobxjs/mobx/issues"
},
"homepage": "http://mobx.js.org/",
"dependencies": {
"mobx-react-lite": "^3.1.1"
},
"peerDependencies": {
"mobx": "^6.0.0",
"react": "^16.8.0 || ^17"
},
"peerDependenciesMeta": {
"react-dom": {
"optional": true
},
"react-native": {
"optional": true
}
},
"devDependencies": {
"mobx": "^6.0.0",
"mobx-react-lite": "^3.1.1"
},
"keywords": [
"mobx",
"mobservable",
"react-component",
"react",
"reactjs",
"reactive"
],
"testPathIgnorePatterns": [
"/node_modules/",
"/\\./"
],
"watchPathIgnorePatterns": [
"<rootDir>/node_modules/"
],
"setupFilesAfterEnv": [
"<rootDir>/jest.setup.ts"
],
"testURL": "http://127.0.0.1/"
}
}
"scripts": {
"lint": "eslint src/**/* --ext .js,.ts,.tsx",
"build": "node ../../scripts/build.js mobx-react",
"build:test": "yarn build --target test",
"test": "jest",
"test:size": "yarn import-size --report . observer",
"prepublish": "yarn build --target publish"
}
}
# mobx-react
[![CircleCI](https://circleci.com/gh/mobxjs/mobx-react.svg?style=svg)](https://circleci.com/gh/mobxjs/mobx-react)
[![Join the chat at https://gitter.im/mobxjs/mobx](https://badges.gitter.im/Join%20Chat.svg)](https://gitter.im/mobxjs/mobx?utm_source=badge&utm_medium=badge&utm_campaign=pr-badge&utm_content=badge)
[![CDNJS](https://img.shields.io/cdnjs/v/mobx-react.svg)](https://cdnjs.com/libraries/mobx-react)
[![Minzipped size](https://img.shields.io/bundlephobia/minzip/mobx-react-lite.svg)](https://bundlephobia.com/result?p=mobx-react-lite)
[![TypeScript](https://badges.frapsoft.com/typescript/code/typescript.svg?v=101)](https://github.com/ellerbrock/typescript-badges/)[![code style: prettier](https://img.shields.io/badge/code_style-prettier-ff69b4.svg)](https://github.com/prettier/prettier)
[![Discuss on Github](https://img.shields.io/badge/discuss%20on-GitHub-orange)](https://github.com/mobxjs/mobx/discussions)
[![View changelog](https://img.shields.io/badge/changelogs.xyz-Explore%20Changelog-brightgreen)](https://changelogs.xyz/mobx-react)
Package with React component wrapper for combining React with MobX.

@@ -41,3 +46,3 @@ Exports the `observer` decorator and other utilities.

This package provides the bindings for MobX and React.
See the [official documentation](https://mobx.js.org/react/react-integration.html) for how to get started.
See the [official documentation](https://mobx.js.org/react-integration.html) for how to get started.

@@ -44,0 +49,0 @@ For greenfield projects you might want to consider to use [mobx-react-lite](https://github.com/mobxjs/mobx-react-lite), if you intend to only use function based components. `React.createContext` can be used to pass stores around.

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc