Kerozu
Kerozu

Reputation: 673

Textarea formats does not indent first line

I am struggling with strange behavior of textarea... I am writing small snippet store for my own needs and I would like to paste a code fragment into textarea and then format it using jQuery library, but sometimes I get very strange output (jQuery library is turned off). Screenshot shows it all: enter image description here

In notepad it looks the way I want it, but in pre tag first line is not indented... Could you explain me why? I am using Ruby and Ruby on Rails if it matters.

Thanks in advance!

Upvotes: 0

Views: 271

Answers (1)

Mark
Mark

Reputation: 347

So, you're populating the textarea from RoR, right?

I don't suppose it's as simple as your <% %> being on a new line, and then your code indenting adding extra spaces in?

Upvotes: 1

Related Questions