Skip to content

w8tcha/StackTraceBeautify

Repository files navigation

StackTraceBeautify

.NET Port of netStack.js

NuGet license

build status

A simple Library for highlighting .NET stack traces. It converts a Stack Trace (String) in to an html highlighted (beautified) String

Stacktrace - Language support

  • English
  • Denmark
  • German
  • Russia
  • Chinese

Demo

Stack Trace Formatter - Online pretty print of .NET stack traces

Initialization

var bs = new StackTraceBeautify()
bs.Beautify(input);

Options

var bs = new StackTraceBeautify(new Options
                           {
                               PrettyPrint = false,
                               FrameCssClass = "st-frame",
                               TypeCssClass = "st-type",
                               MethodCssClass = "st-method",
                               ParamsListCssClass = "st-frame-params",
                               ParamTypeCssClass = "st-param-type",
                               ParamNameCssClass = "st-param-name",
                               FileCssClass = "st-file",
                               LineCssClass = "st-line"
                           });

Ready to go css

pre, code {background-color:#333; color: #ffffff;}
.st-type {color: #0a8472; font-weight: bolder;}
.st-method {color: #70c9ba; font-weight: bolder;}
.st-frame-params {color: #ffffff; font-weight: normal;}
.st-param-type {color: #0a8472;}
.st-param-name {color: #ffffff;}
.st-file {color:#f8b068;}
.st-line {color:#ff4f68;}

Acknowledgments

About

A simple Library for highlighting .NET stack traces. It converts a Stack Trace (String) in to an html highlighted (beautified) String

Topics

Resources

License

Stars

Watchers

Forks

Packages

No packages published

Languages