Suggest a feature
×

Welcome to TagMyCode

Please login or create account to add a snippet.
0
0
 
0
Language: Javascript
Posted by: Rodrigo (Digão) Ferreira
Added: Jun 11, 2020 12:46 PM
Views: 125
Tags: cookie js
  1. function getByteSize(s) {
  2.     return encodeURIComponent('<q></q>' + s).length;
  3. }
  4. getByteSize(document.cookie);