htmlgoogle-code-prettify

How auto justify codes with google code prettify?


I use code-prettify and work like a charm How can I justify codes?

I add this code:

<?php
    echo 1;
        echo 1;
    ?>

But I want print this:

<?php
    echo 1;
    echo 1; //--> remove extra space
?> //--> remove extra space

Solution

  • Google code-prettify is a syntax highlighter, not a code beautifier. Code indentation is usually part of code beautifier.