temp
temp
added type.js and refactored