properly set default value, bind attr correctly