Skip to content
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

Create better typing around simulator options #209

Open
dagda1 opened this issue Aug 15, 2022 · 0 comments
Open

Create better typing around simulator options #209

dagda1 opened this issue Aug 15, 2022 · 0 comments

Comments

@dagda1
Copy link
Contributor

dagda1 commented Aug 15, 2022

Currently, it is too easy to pass the wrong config in when creating a simulation because of this interface

export interface SimulationOptions {
  options?: Record<string, unknown>;

The code below will type check even though clientId is cased incorrectly

     createSimulation(simulator: "auth0",
      options: {
        options:{
          clientId: "[your client-id]"

This codesandbox was a quick spike for one way this could be significantly improved.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant