sylvainpolletvillard / ObjectModel

Strong Dynamically Typed Object Modeling for JavaScript
http://objectmodel.js.org
MIT License
467 stars 30 forks source link

"Can't find variable: initModel" in all browser in iOS 10.1.1 #82

Closed edmundyipll closed 3 years ago

edmundyipll commented 6 years ago

I am developing my project using v3.5.2, at first everything is fine and work in all browsers but when I start testing in iOS 10.1.1, The whole page won't load and a console error came out, "Can't find variable: initModel"

Would like to ask for some help here, thanks..

sylvainpolletvillard commented 6 years ago

Hi, I don't have an iOS device to test, so I'm open to external help. In theory, iOS 10.1.1 has full ES6 support, but it may have implementation bugs. However, this error message is weird. Would it be possible to provide the full stack trace of the error ?

edmundyipll commented 6 years ago

Thanks for the reply, Here's the screenshot of the error stack,,

image

*BasicModels.js stores only the basic predefined models,, like the examples in the docs,,

BasicModels.js image

sylvainpolletvillard commented 6 years ago

It may be related to your bundler configuration that does too agressive tree shaking. What tool are you using to convert ES Modules to a JS bundle ? Webpack, rollup ? Would it be possible to see the final code after compilation, the one that is executed in iOS without source maps ?

edmundyipll commented 6 years ago

I am using webpack@4.8.3 ,, with vue-cli 3,, After build, I can see initModel implementation in vendors js map file,, image

sylvainpolletvillard commented 3 years ago

Closed as outdated and non reproducible. Please create a new issue if this is still a problem with latest version