xLog icon indicating copy to clipboard operation
xLog copied to clipboard

无法打印json

Open denghui1010 opened this issue 7 years ago • 3 comments

String jsonString = "{"name": "Elvis", "age": 18}"; XLog.json(jsonString);

打印不出来..

denghui1010 avatar Jun 30 '17 06:06 denghui1010

@denghui1010

  1. Have you initialize the xLog? If not, an exception would be thrown.
  2. Did you set the log level too high? XLog.json use the DEBUG level

elvishew avatar Jun 30 '17 06:06 elvishew

知道原因了, 在一些华为手机上, debug等级的log不会显示, see this, http://blog.csdn.net/seafishyls/article/details/52198814, so 我建议把打印json设成info等级

denghui1010 avatar Jun 30 '17 08:06 denghui1010

另外, json格式出现了奇怪的缩进, image

denghui1010 avatar Jun 30 '17 08:06 denghui1010