added some frontend code