summaryrefslogtreecommitdiffstats
path: root/testing/web-platform/tests/encrypted-media/util/utf8.js
blob: aea5ad7626d99b2c8b9b64881f7f3131cbcb183a (plain)
1
2
toUtf8 = function( o ) { return new TextEncoder().encode( JSON.stringify( o ) ); }
fromUtf8 = function( t ) { return JSON.parse( new TextDecoder().decode( t ) ); }