Skip to content

state function not work in filtersConfig #11

@s108105

Description

@s108105

trying the local_storage in filtersConfig. but the local storage always generate by UUID.
state: {
types: ['local_storage'],
filters: true,
page_number: true,
page_length: true,
sort: true,
key: 'TF_state_myTableFilter',
},

TableFilter-master\src\tablefilter.js

    // TODO: use for-of
    args.forEach((arg) => {
        if (typeof arg === 'object' && arg.nodeName === 'TABLE') {
            this.tbl = arg;
            this.id = arg.id || `tf_${uuid()}`;
            this.tbl.id = this.id;
        } else if (isString(arg)) {
            this.id = arg;
            this.tbl = elm(arg);
        } else if (isNumber(arg)) {
            startRow = arg;
        } else if (isObj(arg)) {
            this.cfg = arg;
            this.hasConfig = true;
        }
    });

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions