rkit / react-select2-wrapper

Wrapper for Select2
MIT License
163 stars 97 forks source link

hierarchy not support ? #74

Closed tezrik closed 6 years ago

tezrik commented 7 years ago

Hi, I'm having a problem displaying the hierarchy.

dataSelect2 : [
        {
            text : '1',
            children : [
                {
                    text : '2',
                    children : [
                        {text : '5', id : 5},
                        {text : '6', id : 6}

                    ]
                },
                {text : '4', id : 4}
            ]
        },
        {text : '7', id : 7},
        {text : '8', id : 8}
    ]

With this data, only the first 2

rkit commented 6 years ago
dataSelect2 : [
        { text : '1', id: 1 },
        {
            children : [
                {
                    text : '2',
                    children : [
                        {text : '5', id : 5},
                        {text : '6', id : 6}

                    ]
                },
                {text : '4', id : 4}
            ]
        },
        {text : '7', id : 7},
        {text : '8', id : 8}
    ]