What's the best way to apply a drop shadow?
Posted
by jckeyes
on Stack Overflow
See other posts from Stack Overflow
or by jckeyes
Published on 2008-10-27T13:04:14Z
Indexed on
2010/03/31
18:53 UTC
Read the original article
Hit count: 277
What is the best method for applying drop shadows? I'm working on a site right now where we have a good deal of them, however, I've been fighting to find the best method to do it. The site is pretty animation heavy so shadows need to work well with this.
I tried a jQuery shadow pulgin. The shadows looked good and were easy to use but were slow and didn't work well with any animations (required lots of redrawing, very joggy).
I also tried creating my own jQuery extension that wraps my element in a couple gray divs and then offsets them a little bit to give a shadow effect. This worked well. It's quick and responsive to the animation. However, it makes DOM manipulation/traversal cumbersome since everything is wrapped in these shadow divs.
I know there has to be a better way but this isn't exactly my forte. Thoughts?
© Stack Overflow or respective owner