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

feat: return more data from getSuggestedQuery to support tooling #608

Merged
merged 3 commits into from Jun 8, 2020
Merged

Commits on Jun 7, 2020

  1. feat: expose suggestion data to support tooling

    I've added more data to the returned object, to support the development of tooling. Before this change, the returned value would be something like `{ queryName: 'Role' }`, and only by calling the `toString` method, the caller would get more information (the full formatted expression).
    
    With this change, the caller gets more useful data, to build tooling around. Example result:
    
    ```
    {
      queryName: 'Role',
      queryMethod: 'getByRole',
      queryArgs: ['button', { name: /submit/i }],
      variant: 'get'
    }
    ```
    
    The variant now defaults to `get`, to fix a bug that was causing suggestions like `undefinedByRole(…)` to be generated.
    smeijer committed Jun 7, 2020
    Configuration menu
    Copy the full SHA
    5cea4fb View commit details
    Browse the repository at this point in the history
  2. Configuration menu
    Copy the full SHA
    72efd82 View commit details
    Browse the repository at this point in the history

Commits on Jun 8, 2020

  1. Configuration menu
    Copy the full SHA
    fcdf49b View commit details
    Browse the repository at this point in the history