react-code-blocks
                                
                                 react-code-blocks copied to clipboard
                                
                                    react-code-blocks copied to clipboard
                            
                            
                            
                        Uncaught ReferenceError: global is not defined
core.js:221
Uncaught ReferenceError: global is not defined
at capture (core.js:221:28)
at node_modules/react-code-blocks/node_modules/refractor/core.js (core.js:5:15)
at __require2 (chunk-62VDRKYJ.js?v=20a5b317:19:50)
at prism-light.js:2:23
Were you able able to fix this? I'm also getting this error while trying to use react-code-blocks in my React app.
Same. Any luck?
Same here
Uncaught ReferenceError: global is not defined
    at capture (core.js:221:28)
    at node_modules/refractor/core.js (core.js:5:15)
    at __require (chunk-DFKQJ226.js?v=8327f63f:8:50)
    at prism-light.js:2:23
- node: v19.0.0
- vite: v4.1.0
- react: v18.2.0
any fix for this? i have been stuck on this error for days.
https://github.com/vitejs/vite/discussions/5912#discussioncomment-2908994 worked for me