开发者

Can Coderay re-indent C (or C-like) code?

开发者 https://www.devze.com 2023-03-28 16:18 出处:网络
I\'ve got a site that accepts input from newbie coders, and would like to re-indent code so that it is \"properly\" formatted. I\'d be happy with re-indenting the 开发者_开发知识库code as it\'s displa

I've got a site that accepts input from newbie coders, and would like to re-indent code so that it is "properly" formatted. I'd be happy with re-indenting the 开发者_开发知识库code as it's displayed, so it could be a ruby solution, but might also be interested in a JS solution if it could show the user the results before saving.


No. CodeRay is only for syntax highlighting. It doesn't include a proper parser.

0

精彩评论

暂无评论...
验证码 换一张
取 消