Added browser example
Bug fixes for typeof