#importing gifs from json

1 messages ยท Page 1 of 1 (latest)

safe solstice
#

how would i import these?

winter parcel
#

you don't

#

you paste them in your console

safe solstice
#

erm, the gifs

winter parcel
#

you don't

#

that's not what this does

safe solstice
#

but it's exactly what it does

#

exports favorited gifs to json

winter parcel
#

exactly

#

it exports

#

not imports

safe solstice
odd totem
#
// export
copy(JSON.stringify(JSON.stringify(Vencord.Webpack.Common.UserSettingsActionCreators.FrecencyUserSettingsActionCreators.getCurrentValue().favoriteGifs.gifs)));

// import

const clipboardData = PASTE HERE;

Vencord.Webpack.Common.UserSettingsActionCreators.FrecencyUserSettingsActionCreators.updateAsync("favoriteGifs", data => Object.assign(data, JSON.parse(clipboardData)), 0);
#

i didn't test but it probably works

#

do at ur own risk tho

safe solstice
#

overwrite or append?

odd totem
#

append

safe solstice
#

append merges duplicates right

odd totem
#

yes

#

Paste over the PASTE HERE

#

should look like this

cobalt ledge
reef mural
odd totem
#

yes

#

just Object.keys + delete

cold yacht
#

ended up clearing my gifs too, here's what i used
hopefully i dont get termed but we'll see

Vencord.Webpack.Common.UserSettingsActionCreators.FrecencyUserSettingsActionCreators.updateAsync(
    "favoriteGifs",
    data => {
        Object.keys(data.gifs).forEach(k => delete data.gifs[k]);
        return data;
    },
    0
);
odd totem
#

no that's good

#

and you wouldn't get termed

#

if u mess this stuff up worst case scenario u brick your settings and it either completely breaks your discord on all devices or just resets all your discord settings

cold yacht
#

been using vencord/vesktop for a while tho its goated

uncut radish
craggy lark
#

very weird

winter parcel
tired dew
#

how do i import gifs if i copied over the metadata aswell..

tired dew
#

idk how the formatting is supposed to b

craggy lark
#

Iโ€™m guessing it broke

tired dew
#

importing doesnt work

#

i'm pretty sure its broken

#

or soetmhing