simplifyed js.