0

Is there a way to auto-format (in terms of things like indentation etc) the entire buffer or a region in an html file?

  • indent-buffer or indent-region will do that according to the mode rules. Please be more specifc with what you want to do. – Muihlinn Aug 22 at 19:22
  • For example, (in Firefox) view-source:duolingo.com/learn has just 1 single line for the entire html code. I want to be able to make it readable in emacs. – tony Aug 22 at 23:06
  • 1
    You may want to try yasuyk/web-beautify to unminify HTML, CSS or JavaScript/JSON. – Firmin Martin Aug 23 at 3:36
  • Thanks! That worked. – tony Aug 23 at 19:35

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.