Path: csiph.com!news.dns-netz.com!news.freedyn.net!news.mb-net.net!open-news-network.org!.POSTED.178.197.213.187!not-for-mail From: Thomas 'PointedEars' Lahn Newsgroups: comp.lang.javascript Subject: Re: Create cookie from ID of tag Date: Thu, 01 Apr 2021 10:09:23 +0200 Organization: PointedEars Software (PES) Lines: 39 Message-ID: <5455208.DvuYhMxLoT@PointedEars.de> References: <06c15260-54cb-43fd-99f0-cba71b0caa36n@googlegroups.com> <01863a61-d1bf-47ec-9955-1a1579e9aca2n@googlegroups.com> <48e39d8c-ec2d-4759-8ddd-8ac063e510c3n@googlegroups.com> <2578953.mvXUDI8C0e@PointedEars.de> <4641170.31r3eYUQgx@PointedEars.de> <2196370.ElGaqSPkdT@PointedEars.de> <11728310.O9o76ZdvQC@PointedEars.de> Reply-To: Thomas 'PointedEars' Lahn Mime-Version: 1.0 Content-Type: text/plain; charset="ISO-8859-1" Content-Transfer-Encoding: 7Bit Injection-Info: gwaiyur.mb-net.net; posting-host="178.197.213.187"; logging-data="17798"; mail-complaints-to="abuse@open-news-network.org" User-Agent: KNode/4.14.10 Cancel-Lock: sha1:3BG0bsg5+H4/jQGm2Z5wVzOtMmc= Face: iVBORw0KGgoAAAANSUhEUgAAADAAAAAwBAMAAAClLOS0AAAAGFBMVEXTxa4RFk5dUWANED8PFEfy7+MGBiW+n3ZNF/QuAAACaElEQVQ4jVXUwVOcMBQG8Dc7Rc4PUntdWV2uxjDpGaGeozOp1woar4jd5t/v9wLstMwsA/ntlxdCAgUc1hjTc9/JCZfGoo3wG3HdmdAWrIJRHe7GM/TmpY5VFefuVcAkkPbLIaN8rmPmjloyZxgyR3GuJ4K0AGtJ2htz8o7yqikm759fldQXaMpbDzjKAG+8v+AugVTOPO5DOjLvGtUYQwh0CPjnVMyGd+8/GfUB5nLKJDD2aLDh5HYyMDJGDwQIo2ZmZcKbowNmAdB/AzyFhrmF2MHRb0QJJfaAnwGB6orZhoykLzJtGwF/xpYxI1dswomiUj3gTuAIqCn/4C7cULwGNBtwMTk3Y4LfKB5YUaOKBKYtpplm7u0vip8tU1NWWyI/7XdcSuIDoMt6rVHMWT0DbjHPGqDqZVSa6zleLcUTcIKLoMv3ueJluALtAo9B302zPPlrtiVScRdCjXvVh3e3JpYa/jjkuC9N+LrBMlz/eAN4eQijX2EdLo6c5tGGHwLyHFtXk89dDGHwCVhG9T0S/j55AhRZgkMCmUQXJ49TnS1wnQDvw0eAh9ICeMmEFbCnPMFzjAvsWoEWEFdYEx+S0MoUZ1gT1wId8+AF3Bl2OoEu906AUHx5VLw/gXYg/x84loOah/2UYNrgiwSwGO7RfUzVBbx/kgpckumGOi6QirtD6gkLTitbnxNol47S2jVc2vsN5kPqaAHT8uUdAJM4v/DanjYOwmUjWznGfwB7sGtAtor5BgofDuzaRj4kSQAqDakTsKORa3Q3xKi3gE1fhl71KRMqrdZ2AWNNg/YOhQyrVBnb+i+nEg4bsDA+egAAAABJRU5ErkJggg== X-User-ID: U2FsdGVkX19QKZDEi86lJnAWJGUpX8I95htFlw8p0v35D6WL4slYVA== X-Face: %i>XG-yXR'\"2P/C_aO%~;2o~?g0pPKmbOw^=NT`tprDEf++D.m7"}HW6.#=U:?2GGctkL,f89@H46O$ASoW&?s}.k+&. On Tuesday, March 30, 2021 at 5:58:09 PM UTC-5, Thomas 'PointedEars' Lahn > wrote: >> Thank you. My retrieval/storage code (specifically written backwards ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ >> compatible) looks similar, but I found it a good idea to include the ^^^^^^^^^^ >> possibility of the cookie data not being live so as to make access to >> it more efficient. >> >> If you have suggestions for improvement, please let me know: >> >> [...] >> >> jsx.dom.cookies = { >> [...] >> } > > Modernization to modules and other ECMAScript features is my primary > suggestion. See above. > After seeing your local cache I wonder if it's worth extending the Map > class instead: > > class Cookies extends Map { > ... > } > > You would then get the iteration methods and more functionality for free. Thank you, I will consider it. -- PointedEars FAQ: | | Twitter: @PointedEars2 | Please do not cc me./Bitte keine Kopien per E-Mail.