Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Can we set cookie expires time #28

Closed
aspmaker opened this issue Jan 22, 2017 · 4 comments
Closed

Can we set cookie expires time #28

aspmaker opened this issue Jan 22, 2017 · 4 comments

Comments

@aspmaker
Copy link

Hello. Can we set cookie value (smartbanner_exited) in js code ? Example i want to show banner every 15 day and only one time. Thank you.

@ain ain added the question label Jan 23, 2017
@ain
Copy link
Owner

ain commented Jan 23, 2017

Hi @aspmaker, thank you for your interest.

Currently not. At the moment smartbanner.js cookie behaviour mocks the original Apple Smart App banner behaviour by creating a cookie as per browser session.

Nevertheless, I can't see any arguments against such feature and I can see your use-case. I'd gladly accept your Pull Request with this feature.

Before you start, please see contribution guidelines and make sure you add tests against your feature.

@igor10k
Copy link

igor10k commented Feb 23, 2017

@ain Apple docs state that banner won't reappear, so cookie per session doesn't mock the original behavior.

from https://developer.apple.com/library/content/documentation/AppleApplications/Reference/SafariWebContent/PromotingAppswithAppBanners/PromotingAppswithAppBanners.html:

When the user returns to the webpage, the banner won’t reappear.

@ain
Copy link
Owner

ain commented Feb 23, 2017

@igor10k you're probably right. Nevertheless, it's not a good idea to change this behaviour due to legacy reasons, but I'd be more than glad to merge a reasonable PR on this.

@ain
Copy link
Owner

ain commented Aug 9, 2017

Landed in v1.6.0.

@ain ain closed this as completed Aug 9, 2017
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants