woodie / common-cartridge-viewer

View Common Cartridges in the browser
https://common-cartridge-viewer.netlify.com
MIT License
1 stars 0 forks source link

LaTeX support with mathjax3-react #2

Open woodie opened 5 months ago

woodie commented 5 months ago

It looks like this package requires a newer version of React.

$ npm install mathjax3-react --save
npm ERR! code ERESOLVE
npm ERR! ERESOLVE unable to resolve dependency tree
npm ERR!
npm ERR! While resolving: common-cartridge-viewer@0.1.1
npm ERR! Found: react@16.14.0
npm ERR! node_modules/react
npm ERR!   react@"^16.7.0" from the root project
npm ERR!
npm ERR! Could not resolve dependency:
npm ERR! peer react@"18.x" from mathjax3-react@1.2.0
npm ERR! node_modules/mathjax3-react
npm ERR!   mathjax3-react@"*" from the root project
npm ERR!
npm ERR! Fix the upstream dependency conflict, or retry
npm ERR! this command with --force, or --legacy-peer-deps
npm ERR! to accept an incorrect (and potentially broken) dependency resolution.
woodie commented 5 months ago

Alexandre writes, "I recommend upgrading React to version 18 or higher, but I’m not sure if it’s feasible to you at the moment. Alternatively, you may use an older version of the library that does not require React 18 or higher."

woodie commented 5 months ago

OK, some success with npm i mathjax3-react@1.0.8 in the current React 16 app. https://github.com/instructure/common-cartridge-viewer/pull/202/files