src/BlazorWerks/wwwroot/bwerks.bundle.js
// Let .NET access native storage via wrapper object rather than directly
Let .NET access native storage via wrapper object rather than directly
Let . NET access native storage via wrapper object rather than directly
function StorageWrapper(base) {
        return {
            getItem: function (key) {
                return base.getItem(key);
            },
            setItem: function (key, value) {
                base.setItem(key, value);
            },
            removeItem: function(key) {
                base.removeItem(key);
            },
            clear: function () {
                base.clear();
            },
            key: function (index) {
                return base.key(index);
            },
            length: function () {
                return base.length;
            },
            keys: function () {
                let k = [];
                for (let i = 0; i < base.length; i++) {
                    k.push(base.key(i));
                }
                return k;
            }
        }
    }
function StorageWrapper ( base ) { return { getItem : function ( key ) { return base . getItem ( key ) ; } , setItem : function ( key , value ) { base . setItem ( key , value ) ; } , removeItem : function ( key ) { base . removeItem ( key ) ; } , clear : function ( ) { base . clear ( ) ; } , key : function ( index ) { return base . key ( index ) ; } , length : function ( ) { return base . length ; } , keys : function ( ) { let k = [ ] ; for ( let i = 0 ; i < base . length ; i ++ ) { k . push ( base . key ( i ) ) ; } return k ; } } }
Let .NET access native storage via wrapper object rather than directly
Let . NET access native storage via wrapper object rather than directly