Is there any best practice how to detect a first run of the app?

为君一笑 提交于 2019-12-11 05:59:51

问题


Is there an easy and smooth way how to detect if an app is run the first time? I know, it would be possible to set a cookie and check if it exists but is there another - maybe even better - way?


回答1:


I take it that you mean first time on a given computer, as distinct from first time in a given document or first time by a given user. In that case, the cookie, or local storage, is probably your easiest/smoothest strategy. If your add-in is going to have a server-side storage of purchasers/clients/users anyway, then you could also use a flag in that storage. This SharePoint tutorial is an example of a server-side strategy.



来源:https://stackoverflow.com/questions/50756976/is-there-any-best-practice-how-to-detect-a-first-run-of-the-app

标签
易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!