Tiggr.persistentStorage example

Can you provide a simple example of how to set a variable via Tiggr.persistentStorage?

Just as a quick test, I'm trying to implement a counter that increases each time the application is run.

var count = parseFloat(Tiggr.getItemFromStorage('count'));
if (isNaN(count)){ count = 0;}

I also tried Tiggr.persistentStorage('count',count+1); with no luck either. Hopefully you can point me in the right direction.

1 person has
this question
This topic is no longer open for comments or replies.