Runtime conditional configuration of afterDeserialize? #1768
Unanswered
ivan-codes-foss
asked this question in
Q&A
Replies: 0 comments
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
Hello,
I am looking for the ability to configure a custom value for afterDeserialize based on some runtime condition. I'm running into AoT errors "Only initialized variables and constants can be referenced in decorators...". The only way I could find to make it work was to declare the import as NgxsStoragePluginModule.forRoot({}) and monkey patch NGXS_STORAGE_PLUGIN_OPTIONS via a custom implementation of storageOptionsFactory. Is there a better way?
Beta Was this translation helpful? Give feedback.
All reactions