implemented two way data binding