fonsp / Pluto.jl

🎈 Simple reactive notebooks for Julia
https://plutojl.org/
MIT License
4.94k stars 285 forks source link

Have a way to use Pluto default `show` for types which define a custom `show` method #2997

Open disberd opened 1 month ago

disberd commented 1 month ago

Currently, if I create a type MyType and define a override Base.show(io::IO, x::MyType) or Base.show(io::IO, ::MIME"text/plain", x::MyType), then I lose the default show method in Pluto, and there is not method to get it back.

It would be good to be able to decide I want my type to have a custom show in the REPL but do not impact the Pluto default show method.

I remember somebody raised this issue question before in either zulip/discourse but can't find it anymore.

Discussed this today at the dev call and @fonsp also agrees that we should have this capability

cstjean commented 4 weeks ago

Having a way to "display this object as a Pluto object tree of ..." would also be very nice!