Added frontend script and wrote it almost completely.