Using semantic-ui-react.min.js in a script tag doesn't work, e.g. when trying to externalise the dependency in webpack and use a CDN-build instead.
<!DOCTYPE html>
<html>
<body>
This does't work!
<script src="https://cdnjs.cloudflare.com/ajax/libs/react/16.8.5/umd/react.production.min.js"></script>
<script src="https://cdnjs.cloudflare.com/ajax/libs/react-dom/16.8.5/umd/react-dom.production.min.js"></script>
<script src="https://cdnjs.cloudflare.com/ajax/libs/semantic-ui-react/0.86.0/semantic-ui-react.min.js"></script>
</body>
</html>
Semantic-ui-react.min.js is available in the webpage
The following error occurs in the console:
semantic-ui-react.min.js:1342 Uncaught TypeError: Cannot assign to read only property 'exports' of object '#<Object>'
at Module.<anonymous> (semantic-ui-react.min.js:1342)
at Module.<anonymous> (semantic-ui-react.min.js:1342)
at n (semantic-ui-react.min.js:1)
at semantic-ui-react.min.js:1
at semantic-ui-react.min.js:1
at semantic-ui-react.min.js:1
at semantic-ui-react.min.js:1
0.86.0 (doesn't work with 0.85.0 either).
Also tested with different versions of react/react-dom (16.3.0 / 16.6.0 / 16.8.5).
馃憢 Thanks for opening your first issue here! If you're reporting a 馃悶 bug, please make sure you've completed all the fields in the issue template so we can best help.
We get a lot of issues on this repo, so please be patient and we will get back to you as soon as we can.
I can confirm 0.84.0 works as it should
Thanks for the report 馃憤 Fixed in #3540, next release will work as expected 馃殌 I also added a test to ensure that build works as expected
Most helpful comment
Thanks for the report 馃憤 Fixed in #3540, next release will work as expected 馃殌 I also added a test to ensure that build works as expected