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

Allow assign to take a map #291

Merged
merged 1 commit into from
Sep 16, 2022
Merged

Allow assign to take a map #291

merged 1 commit into from
Sep 16, 2022

Conversation

amclain
Copy link
Member

@amclain amclain commented Sep 15, 2022

Description

This PR allows assign to take a map of values, like Phoenix does.

Motivation and Context

When working on a Scenic project, we captured the entire scene.assigns and transformed a few values. We received an error when trying to assign this resulting map back to the scene, since scene.assigns gave us a map. We referenced Phoenix's behavior of assigns since that was motivation for bringing it into Scenic, and Phoenix does in fact allow both a keyword list or map as assigns. Therefore we thought we should allow for assigning a map in Scenic as well.

Happy to discuss if this either isn't desired or should be implemented differently.

Types of changes

  • Bug fix (a non-breaking change which fixes an issue)
  • New feature (a non-breaking change which adds functionality)
  • Breaking change (fix or feature that would cause existing functionality to
    not work as expected)
  • Improvement/refactoring (non-breaking change that doesn't add any feature
    but make things better)

Checklist

  • Check other PRs and make sure that the changes are not done yet.
  • The PR title is no longer than 64 characters.

Co-authored-by: John Cotton <john@1080people.com>
@boydm boydm merged commit 87e52a1 into ScenicFramework:master Sep 16, 2022
@amclain amclain deleted the assign-map branch September 16, 2022 05:07
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

Successfully merging this pull request may close these issues.

3 participants