Does anyone have a working example of persisting s...
# intellij-plugins
m
Does anyone have a working example of persisting state/settings in a plugin? I followed the docs and even just copy pasted the example into my project and i still get this warning that the state cant be serialized and the values arent persisted across reset
WARN - #c.i.u.x.Binding - No accessors for intellijplugin.toolWindow.tabs.MySettings$State. This means that state class cannot be serialized properly. Please see https://jb.gg/ij-psoc
👀 1
t
I do not use this for persistent settings but i use the other thing called PropertiesComponent Not sure if you are interested. But it works for me.
a
Maybe you encounter this issue https://youtrack.jetbrains.com/issue/IJPL-188400/SerializablePersistentStateComponent-is-not-persisted? I also failed to use the most modern class for the settings, but using the base one works fine, though it is probably not an ideal implementation https://github.com/AleksandrSl/intellij-luau/blob/main/src%2Fmain%2Fkotlin%2Fcom%2Fgithub%2Faleksandrsl%2Fintellijluau%2Fsettings%2FProjectSettingsState.kt