rework js tree + search impl start