Update js

Added further support for editing - need to make edited code parse