At the moment I don't have any code, because I don't know where to start.
I have to manage subscription on my app. So, if user installed the app on 8th Sep then it will get renewed automatically on 8th October similar for every month. But I would like to show days remaining.
I have stored the date of installation in database. For one month I can do that easily using moment.js or angular way. Like below.
var a = moment([2017, 09, 29]);
var b = moment([2017, 10, 28]);
Math.abs(a.diff(b, 'days'))+1
How can I achieve this?
More explanation
I don't need to get the current date. I want to show renew days for subscription. If someone installed on 4th Aug then it get renewed automatically on 4th Sep and next renew date will be 4th Oct. So, I want to show days remaining till 4th Oct.