Implementing android app in purchase full guide?

I’ve read this https://blog.nraboy.com/2014/08/making-android-app-purchases-ionicframework/ but I don’t know how to continue. I have 2 big question in my head.

  1. is this how app in purchase work?
    like the user have purchased and I can get that data, eg. purchased = true, the in my controller I do ng-show=’'purchased==true" to give user extra feature. Correct?

  2. In above blog post, I have to debug using a real device. In this code

if((window.device && device.platform == “Android”) && typeof inappbilling !== “undefined”) {
inappbilling.init(function(resultInit) {
console.log(“IAB Initialized”);
},
function(errorInit) {
console.log("ERROR -> " + errorInit);
},
{showLog: true},
[“productId1”, “productId2”, “productId3”]);
}

how can I see the console.log in my device?