🚀 Feature: Soft-deprecate noHighlighting #3701
Labels
area: browser
browser-specific
area: usability
concerning user experience or interface
status: accepting prs
Mocha can use your help with this one!
noHighlighting
is a browser-only option can supply which disables syntax highlighting.It should probably be replaced with a reporter option (though open to debate!), since it's unique to the
html
reporter. This should be a boolean option which defaults totrue
.If a user supplies
{noHighlighting: true}
tomocha.setup()
or callsmocha.noHighlighting()
in the browser, we should print a deprecation message along the lines of "noHighlighting is deprecated; provide{reporterOption: {highlight: false}}
tomocha.setup()
.This is what needs to be done:
Mocha
constructor for examples.utils.deprecate(...)
withinMocha#noHighlighting
.html
reporter's constructor should accept areporterOptions
object, which may beundefined
, and may have a booleanhighlight
property. If the property is anything other than explicitlyfalse
, default totrue
Mocha.utils.highlightTags('code')
when theend
event is emitted by therunner
property; use the check fordocument
found here and the value ofhighlight
prop passed inreporterOptions
.browser-entry.js
.test/unit/mocha.spec.js
.docs/index.md
) about the deprecation and new behavior.The text was updated successfully, but these errors were encountered: