jQuery API implementation using "pure" ES