the part of js is nearly finished