JS widget foundation