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

Recursively resolve map values #133

Merged
merged 2 commits into from
Dec 1, 2018
Merged

Conversation

RedHatter
Copy link
Contributor

Closes #118

Recursively resolves map values so you can access maps within your maps. Consider the following example.

colors.yal

red: '#b71c1c'

palette.yal

main: map(colors, red)

input

a {
  color: map(palette, main);
}

output

a {
    color: #b71c1c;
}

This would also work for referencing values within the same map.

palette.yml

main: '#b71c1c'
text-color: map(palette, main)

@coveralls
Copy link

Coverage Status

Coverage decreased (-3.3%) to 96.667% when pulling 36e42b4 on RedHatter:recusive-map into efcdc96 on pascalduez:master.

1 similar comment
@coveralls
Copy link

Coverage Status

Coverage decreased (-3.3%) to 96.667% when pulling 36e42b4 on RedHatter:recusive-map into efcdc96 on pascalduez:master.

@coveralls
Copy link

coveralls commented Nov 26, 2018

Coverage Status

Coverage remained the same at 100.0% when pulling 555c7cf on RedHatter:recusive-map into efcdc96 on pascalduez:master.

Copy link
Owner

@pascalduez pascalduez left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Lookin' good! Thanks.

@pascalduez pascalduez merged commit 01afa49 into pascalduez:master Dec 1, 2018
@pascalduez
Copy link
Owner

[email protected]

@pascalduez
Copy link
Owner

Should be documented though, now that's a "true" and tested feature.

@RedHatter RedHatter deleted the recusive-map branch December 1, 2018 17:36
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.

Map within Maps?
3 participants