What is the Crystal equivalent shard for "pp" used in Ruby for pretty printing complex data structures ?
Asked
Active
Viewed 441 times
1 Answers
6
PrettyPrint is a part of a Crystal stdlib.
In short, you can just do p obj
for "inspect" style output, pp obj
for "pretty inspect" style output.

rogerdpack
- 62,887
- 36
- 269
- 388

Vitalii Elenhaupt
- 7,146
- 3
- 27
- 43
-
1The correct answer is just `p obj`. `pp obj` will also print the expression you are printing. – asterite Nov 06 '17 at 13:32