-2
$('#scroller').css('transform');

This div is a default value.

Transform scale(1)

i want to change value. if #scroller transform scale(3) give me alert?

Thanks

Mritunjay
  • 25,338
  • 7
  • 55
  • 68

1 Answers1

0

$('#scroller').css('transform', 'scale(3)'); alert('Changed');

The css change will always execute before the alert. See also In JQuery, Is it possible to get callback function after setting new css rule?

Community
  • 1
  • 1
lynt
  • 136
  • 1
  • 5
  • Additionally `$('#scroller').css('transform', 'scale(3)')` will be 'truthy' even when there is no div on the page called #scroller, so if you had an if statement it will always run. – lynt Aug 26 '14 at 13:07