react-katex
react-katex copied to clipboard
Possible merge?
Hi, I would like to find a common path where we can merge this repo (I used my starter for react lib and the source code is completely rewritten but the readme is forked from yours) with your repo. Do you think it's possible?
Differences:
- components are merged into the one
<TeX>which hasprops.blockfor indicating block math (breaking change) - KaTeX is moved into the
peerDependencies(so users don't need to wait for updating this lib, it should be their responsibility) - the size of the lib is now correct because it doesn't include the whole katex library
-
<TeX />component is memoized (newReact.memo(Component)) by default so you can avoid unnecesary rerenders - from the previous is clear that it needs React >=16.6.0
-
<TeX />component accepts other props (likeclassName,id,style,...) which are given to thespan/div - added
props.settingsfor KaTeX configuration - examples in repo are accessible (live) via codesandbox
- tests are done with Jest (with snapshots) and
react-testing-library - added husky+lint-staged+prettier-eslint for formatting before commiting
- it is bundled with microbundle (multiple outputs: ESM, UMD, CJS)
What do you think?
Update:
- types added (https://github.com/MatejBransky/react-katex/pull/3 - thanks to https://github.com/shilangyu)
- the new prop
asadded (https://github.com/MatejBransky/react-katex/pull/9 - thanks to https://github.com/tywmick)
Hi @talyssonoc, any interest in merging the changes by @MatejBransky into upstream?