added type to js elements