aboutsummaryrefslogtreecommitdiffstats
path: root/resources/src/mediawiki.cookie/jar.js
Commit message (Collapse)AuthorAgeFilesLines
* eslint: Manually enforce prefer-const in all remaining codeEd Sanders2024-10-051-1/+1
| | | | Change-Id: Ic9f254b55d3936f351ba9c7cc3b553544fc63a58
* eslint: Autofix var to let/constEd Sanders2024-09-121-10/+10
| | | | | | | Temporarily disable no-var & prefer-const as resulting errors need to be fixed manually. Change-Id: I6cb62a2c70a4c1fc265a00b1f18af127ac9d5029
* Cookie: Document in jsdocJon Robson2023-12-151-15/+7
| | | | | | | | | | Changes: * Switch from mixed to string|null since cookies always cast to a string. For example `mw.cookie.set('foo',6)` results in '6' and `mw.cookie.set('foo',[1,2,3])` results in '1,2,3'. Bug: T35230 Change-Id: I4a27abe6b430fef75506df129f3168dcc4bbd565
* mediawiki.cookie: Remove eslint overridesEd Sanders2023-11-171-33/+33
| | | | Change-Id: If43cdc85c7b774ce3c99804c1ed24c77572bc6ae
* mediawiki.cookie: Do not throw error when cookies are not readableGergő Tisza2023-11-141-10/+21
| | | | | | | This can happen when the document is sandboxed. Bug: T169027 Change-Id: If915b31a9eef8a92123bb9b566ad4fc69be6d92d
* mediawiki.cookie: Adds docs for internal jar and $.cookieTimo Tijhof2023-05-011-3/+34
| | | | | | | It's quite a quirky method to use as the basis for mw.cookie, but it is was it is right now. Start documenting how it actually works. Change-Id: Ia79901627fb2fd6594865cb84a0956feba7abd06
* mediawiki.cookie: Factor out internal jar interface from $.cookieJon Robson2023-05-011-0/+105
Update these libraries so they do not depend on each other, but instead create 2 entry points to the same library. Follow up to I8cab36357535b3994e65f9ee81779479a72805d7 jquery.cookie was only using $.extend and given we are using ES6 now, we can remove that dependency so this doesn't rely on jQuery at all. The library is renamed to jar.js and the header is updated to reflect the fact that it has been forked from the upstream library. References to $.cookie inside index.js now directly access jar, however $.cookie is retained as a convenience function to access the library to keep support with gadgets. Bug: T271995 Change-Id: I47ad1c56d514502c468947ed7c22915740915f85