statsig-io / node-js-server-sdk

Statsig's SDK for server-side Node.js applications.
ISC License
20 stars 15 forks source link

Add clearAll Gate, Config, Layer overrides methods #42

Closed neil176 closed 8 months ago

neil176 commented 8 months ago

Introduces 3 new methods to the top level StatsigServer class, each of which calls into the Evaluator to set its respective backing object to an empty object:

Please let me know if different naming would help or if there is associated documentation/tests that should be updated.

Resolves statsig-io/node-js-server-sdk#41

neil176 commented 8 months ago

Converted back to draft as I just realized I didn't propagate this change all the way up. Will pick back up with it tomorrow.

neil176 commented 8 months ago

@tore-statsig Please let me know if I've missed anything in here and I'll be happy to correct it, I don't work much outside of internal codebases these days.

tore-statsig commented 8 months ago

Thanks! This looks good. Im pulling it in to our private version of the sdk repository, added some test cases, and running our integration test runner before releasing a new version. Thanks for the contribution!