Skip to content
This repository has been archived by the owner on Dec 31, 2020. It is now read-only.

5.4.0 CDN version cannot be used #608

Closed
flyinghail opened this issue Nov 20, 2018 · 6 comments
Closed

5.4.0 CDN version cannot be used #608

flyinghail opened this issue Nov 20, 2018 · 6 comments

Comments

@flyinghail
Copy link

ReferenceError: require is not defined

The reason for the error is this code:

require("react-is")
@mweststrate
Copy link
Member

mweststrate commented Nov 20, 2018 via email

@flyinghail
Copy link
Author

flyinghail commented Nov 20, 2018

@mweststrate

https://unpkg.com/mobx-react@5.4.0/index.min.js

https://unpkg.com/mobx-react@5.3.6/index.min.js can be used, but 5.4.0 does not work

@mweststrate
Copy link
Member

@flyinghail seems to be a rollup issue, 5.4.1 should fix it, could you confirm?

@mweststrate mweststrate reopened this Nov 20, 2018
@flyinghail
Copy link
Author

flyinghail commented Nov 20, 2018

@mweststrate there is a new error

Error: render property of ForwardRef was not a function

@mweststrate
Copy link
Member

mweststrate commented Nov 20, 2018 via email

@flyinghail
Copy link
Author

flyinghail commented Nov 20, 2018

@marksilvis I see the code.
ReactIs.ForwardRef is coverted to undefined in CDN version.
New issue: #609

noscripter added a commit to noscripter/mobx-react that referenced this issue Nov 30, 2018
* fix: jest test jsdom SecurityError

ref:  jsdom/jsdom#2304

* Add link to mobx-react-lite (mobxjs#603)

* Create a failing test for React.forwardRef

* Refs are now properly forwarded

* observer + forwardRef is now reactive

* Minor tweak, updated changelog

* Fixed weird minification issue

* Published version 5.4.0

* Fixed rollup issue, fixes mobxjs#608

* Published version 5.4.1

* Fixed issue with ForwardRef being bundled as undefined

* Published version 5.4.2

* Cleaner implementation of forwardRef

* Added open question
@github-actions github-actions bot mentioned this issue Oct 13, 2020
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants