Cap-go / capacitor-inappbrowser

Capacitor plugin in app browser with urlChangeEvent
MIT License
58 stars 37 forks source link

Clear cache and session #67

Closed asieverding closed 6 months ago

asieverding commented 10 months ago

Hey there :) Is there an option to clear browser cache and session? I would like to use the in app browser to process an OAuth login with Microsoft services, but after a logout I need to clear cache and session. Otherwise the OAuth flow authenticates the same user account without login with mail and password the next time the in app browser is opened.

asieverding commented 10 months ago

Some options like clearcache or clearsessioncache for example. Like in the https://www.npmjs.com/package/cordova-plugin-inappbrowser plugin.

riderx commented 10 months ago

Hello thanks for the report, if you are willing to support the project someone from the community can make it for you: https://github.com/sponsors/riderx

riderx commented 10 months ago

/bounty 50

algora-pbc[bot] commented 10 months ago

๐Ÿ’Ž $50 bounty created by Capgo ๐Ÿ™‹ If you start working on this, comment /attempt #67 to notify everyone ๐Ÿ‘‰ To claim this bounty, submit a pull request that includes the text /claim #67 somewhere in its body ๐Ÿ“ Before proceeding, please make sure you can receive payouts in your country ๐Ÿ’ต Payment arrives in your account 2-5 days after the bounty is rewarded ๐Ÿ’ฏ You keep 100% of the bounty award โ„น๏ธ If something is not clear ask before working on it, otherwise your chance to rework it is high ๐ŸŽฅ To claim you need to provide in your PR a demo video of the change ๐Ÿ‘จโ€๐Ÿ‘ฉโ€๐Ÿ‘งโ€๐Ÿ‘ฆ Join the Discord to get help ๐Ÿ“ Check all Bounty rules ๐Ÿ™ Thank you for contributing to Cap-go/capacitor-inappbrowser!

Attempt Started (GMT+0) Solution
๐Ÿ”ด @ayusham001 Sep 1, 2023, 5:36:21 PM WIP
๐ŸŸก @jessmathews Sep 3, 2023, 5:19:23 AM #85
ayusham001 commented 10 months ago

/attempt #67

Options
jessmathews commented 10 months ago

/attempt #67

Options
algora-pbc[bot] commented 10 months ago

Note: The user @ayusham001 is already attempting to complete issue #67 and claim the bounty. If you attempt to complete the same issue, there is a chance that @ayusham001 will complete the issue first, and be awarded the bounty. We recommend discussing with @ayusham001 and potentially collaborating on the same solution versus creating an alternate solution.

algora-pbc[bot] commented 10 months ago

@ayusham001: Reminder that in 7 days the bounty will become up for grabs, so please submit a pull request before then ๐Ÿ™

algora-pbc[bot] commented 9 months ago

@jessmathews: Reminder that in 7 days the bounty will become up for grabs, so please submit a pull request before then ๐Ÿ™

jessmathews commented 9 months ago

hey @riderx has this issue been solved? do I need to add to the readme after adding the clearcache or clearsessioncache functionality?

riderx commented 9 months ago

Thanks for solving this, the readme is auto update when you update the TS file, just run the build command. Please also run the lint and verify to be sure all build

jessmathews commented 9 months ago

I ran

npm run lint
npm run build 
npm run verify:web && npm run verify:android

The only errors were /home/user/capacitor-inappbrowser/src/definitions.ts 0:0 error Parsing error: DeprecationError: 'originalKeywordKind' has been deprecated since v5.0.0 and can no longer be used. Use 'identifierToKeywordKind(identifier)' instead Everything else worked fine.

algora-pbc[bot] commented 9 months ago

๐Ÿ’ก @jessmathews submitted a pull request that claims the bounty. You can visit your org dashboard to reward.

asieverding commented 9 months ago

any updates?

algora-pbc[bot] commented 6 months ago

๐ŸŽ‰๐ŸŽˆ @jessmathews has been awarded $50! ๐ŸŽˆ๐ŸŽŠ

riderx commented 6 months ago

This has been merged and fixed ! sorry for the delay

asieverding commented 4 months ago

Can someone provide an example how to use it correctly? I want to clear the cache of the in app browser completly. The new feature is bound to the clearCookies function and requires an url but even if I enter a url and set the cache option to true, the cache is not deleted.

Is only the cookie cache deleted or also the session cookie cache?