Bug Tracker

Opened 13 years ago

Closed 13 years ago

Last modified 13 years ago

#6868 closed bug (fixed)

$.trim very expensive on long strings

Reported by: kemayo Owned by:
Priority: undecided Milestone: 1.4.3
Component: unfiled Version: 1.4.2
Keywords: Cc:
Blocked by: Blocking:


I ran $.trim on a ~17kB string, and it caused my browser to ask me if I wanted to stop an unresponsive script.

Change History (3)

comment:1 Changed 13 years ago by dfens

  <script language="javascript" src="http://ajax.googleapis.com/ajax/libs/jquery/1.4.2/jquery.js"></script>
$(document).ready(function() {
  var txt = "   ";
  for (var i =0; i <1700;i++)
  txt += "                          ";

  <div class="inner">


works fine

comment:2 Changed 13 years ago by dmethvin

Priority: undecided
Resolution: fixed
Status: newclosed

comment:3 Changed 13 years ago by dmethvin

#7477 is a duplicate of this ticket.

Note: See TracTickets for help on using tickets.