##// END OF EJS Templates
Merge pull request #11852 from danielballan/formatter-usage...
Matthias Bussonnier -
r25166:4842416d merge
parent child Browse files
Show More
@@ -85,7 +85,7 b' Formatters for third-party types'
85 85
86 86 The user can also register formatters for types without modifying the class::
87 87
88 from bar import Foo
88 from bar.baz import Foo
89 89
90 90 def foo_html(obj):
91 91 return '<marquee>Foo object %s</marquee>' % obj.name
@@ -94,7 +94,7 b' The user can also register formatters for types without modifying the class::'
94 94 html_formatter.for_type(Foo, foo_html)
95 95
96 96 # Or register a type without importing it - this does the same as above:
97 html_formatter.for_type_by_name('bar.Foo', foo_html)
97 html_formatter.for_type_by_name('bar.baz', 'Foo', foo_html)
98 98
99 99 Custom exception tracebacks
100 100 ===========================
General Comments 0
You need to be logged in to leave comments. Login now