Add an extended_deref method to JSRef

The extended_deref method will take a JSRef<'a, T> and produce an &'a T,
in contrast to the standard deref method that takes an &'b JSRef<'a, T>
and produces an &'a T. This is useful when avoiding passing a JSRef by
reference.
Make the AttrHelpers trait use extended_deref
Make the DocumentHelpers trait use extended_deref
Merge pull request #3497 from zwarich/extended-deref

Add an extended_deref method to JSRef

Reviewed-by: Manishearth