-
Notifications
You must be signed in to change notification settings - Fork 15
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
feat: provide reset last config method #73
base: master
Are you sure you want to change the base?
feat: provide reset last config method #73
Conversation
2b99d90
to
64674db
Compare
let lastConfig = null; | ||
const wireInstances = new Set(); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
With this approach, we generate each time a new class and we don't expose directly the lastConfig
and wireInstances
variables. Then we ensure to not have some troubles with inheritances
static resetLastConfig() { | ||
lastConfig = null; | ||
} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The new method
64674db
to
3b87e2d
Compare
@nolanlawson sorry to ping you: do you know which team should I at-mention to review this PR please? Many thanks for your help |
@rochejul The LWC team (my team) owns this. |
Many thanks |
Related to issue #71 , this PR contains the ability for each adapter to have a
resetLastConfig
method.This pr contains:
I needed to revisit the adapters' inheritance because for some inheritance troubles, the last Apex use case fails when we test the
getLastConfig
:I have the feeling the case n°2 mutate the adapter and then when we call the
restLastConfig
on it, the next calls ofgetLastConfig
will fail.With the refactoring, everything works now