AnyRoad / react-json-view-lite

Lightweight Json view component for React
155 stars 14 forks source link

Adding custom renderer #15

Open DavoCg opened 11 months ago

DavoCg commented 11 months ago

Hi,

first of all thanks for this light package that does very well what it aims to. Would you consider adding the ability to add custom renderer for every primitives ? While it might not be useful for boolean, it can be nice for string value (ex: you want to wrap an url in an )

The change could be pretty simple, happy to open a PR if it's something you consider adding.

Thanks

AnyRoad commented 11 months ago

Hi,

Thank you for the suggestion! it is definitely good to make library more versatile, my main concerns are performance and library size. I think if by default (without any cusom renderers) library will be same fast and it will not increase bundle size too much then PR is more than welcome!

Thanks!