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: Adjust how aliases are formatted #4750

Open
wants to merge 5 commits into
base: main
Choose a base branch
from

Commits on Jul 17, 2024

  1. feat: Adjust how aliases are formatted

    This proposes to adjust how aliases are formatted.
    
    Currently we include a space around `=`, which means we get the quite reasonable:
    
    ```elm
    sum_gross_cost = sum gross_cost
    ```
    
    ...but also the quite confusing:
    
    ```elm
    join side:left manager = employees e.reports_to == manager.employee_id`
    ```
    
    There, the _least_ two bound items appear to be `manager` & `employees`, but in fact those are bound.
    
    So this proposes to change these to:
    - Remove spaces around `=` in aliases
    - Add parentheses if the rvalue contains multiple items
    
    So now we get:
    
    ```elm
    join side:left manager=employees e.reports_to == manager.employee_id`
    ```
    
    ...while the standard case here becomes arguable a bit worse, but still quite reasonable:
    
    ```elm
    sum_gross_cost = (sum gross_cost)
    ```
    
    What do folks think?
    max-sixty committed Jul 17, 2024
    Configuration menu
    Copy the full SHA
    4089efe View commit details
    Browse the repository at this point in the history

Commits on Jul 18, 2024

  1. wip, not quite working yet

    max-sixty committed Jul 18, 2024
    Configuration menu
    Copy the full SHA
    36f144a View commit details
    Browse the repository at this point in the history
  2. Configuration menu
    Copy the full SHA
    00b0ea8 View commit details
    Browse the repository at this point in the history
  3. No commit message

    max-sixty committed Jul 18, 2024
    Configuration menu
    Copy the full SHA
    4a979f5 View commit details
    Browse the repository at this point in the history
  4. No commit message

    max-sixty committed Jul 18, 2024
    Configuration menu
    Copy the full SHA
    bd3e758 View commit details
    Browse the repository at this point in the history