some debugging of js