mobx-utils icon indicating copy to clipboard operation
mobx-utils copied to clipboard

mobx.makeObservable is not a function?

Open nickperkinslondon opened this issue 5 years ago • 4 comments

{ createViewModel } = require 'mobx-utils'	

thing = mobx.observable({
    attr:'value'
})

vm = createViewModel(thing)

TypeError: mobx.makeObservable is not a function at new ViewModel (D:\Dropbox\workspace\npl\node_modules\mobx-utils\mobx-utils.umd.js:633:18) at createViewModel (D:\Dropbox\workspace\npl\node_modules\mobx-utils\mobx-utils.umd.js:779:16)

nickperkinslondon avatar Oct 28 '20 18:10 nickperkinslondon

$ npm view mobx version 6.0.1 $ npm view mobx-utils version 6.0.1

nickperkinslondon avatar Oct 28 '20 18:10 nickperkinslondon

This is most likely a problem with your local node_modules or project setup. Not much we can do here, unless you can provide a minimal reproduction, in which most probably the issue won't occur at all.

On Wed, Oct 28, 2020 at 6:24 PM Nick Perkins [email protected] wrote:

$ npm view mobx version 6.0.1 $ npm view mobx-utils version 6.0.1

— You are receiving this because you are subscribed to this thread. Reply to this email directly, view it on GitHub https://github.com/mobxjs/mobx-utils/issues/281#issuecomment-718123569, or unsubscribe https://github.com/notifications/unsubscribe-auth/AAN4NBAQP26IJQRKBK23FDTSNBOVZANCNFSM4TCWI6PA .

mweststrate avatar Oct 29 '20 22:10 mweststrate

I get this warning: WARNING in ../node_modules/mobx-utils/mobx-utils.module.js 629:8-22 "export 'makeObservable' was not found in 'mobx' mobx: 5.15.4 mobx-utils: 6.0.1

this might have something to do with version 6.0.1 of mobx-utils, since when I downgraded to 5.6.1 it stopped.

yaarams avatar Jan 06 '21 13:01 yaarams

Please update to MobX 6, and respect peer dependency warnings when running yarn / npm install :)

On Wed, Jan 6, 2021 at 1:19 PM Yaara Cohen [email protected] wrote:

I get this warning: WARNING in ../node_modules/mobx-utils/mobx-utils.module.js 629:8-22 "export 'makeObservable' was not found in 'mobx' mobx: 5.15.4 mobx-utils: 6.0.1

— You are receiving this because you commented. Reply to this email directly, view it on GitHub https://github.com/mobxjs/mobx-utils/issues/281#issuecomment-755294588, or unsubscribe https://github.com/notifications/unsubscribe-auth/AAN4NBHQB7EL6XQKCYPBPLTSYRPPBANCNFSM4TCWI6PA .

mweststrate avatar Jan 06 '21 13:01 mweststrate