How to convert code block into single line?

Asked

Viewed 11,643 times

10

I need to convert certain blocks of code into a single line.

How can I do that? I’m using Notepad++

3 answers

15


CTRL + To to select the code block and then CTRL + J to join the lines.

The option of joining the lines is also available, through the menu: Edit>Line Operations>Join lines

  • Perfect! That’s right. Thank you.

5

I believe that the best you will achieve is to make a "Replace" killing the line breaks. Usually composed by the characters of Carriage Return and line feed (\r\n).

Replace Notepad++

2

The name of this "feature" is minimize/Minify and you can do this using online apps.

It’s them:

Htmlcompressor

Textfixer

The issue of leaving in 1 line is irrelevant because the intention is to leave the code "messy".

Browser other questions tagged

You are not signed in. Login or sign up in order to post.