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: add support for state groups for the Remove relation #17

Merged
merged 2 commits into from
Feb 22, 2024

Conversation

pancsta
Copy link
Owner

@pancsta pancsta commented Feb 22, 2024

Ability to define a mutually exclusive state group and using it for the Remove relation for all the states from that group.

Reduces repetition, increases readability.

var GroupPlaying = am.S{
	Playing, Paused, LiveView,
}

var States = am.States{
	Playing: {
		Remove: GroupPlaying,
	},
	Paused: {
		Remove: GroupPlaying,
	},
	LiveView: {
		Remove: GroupPlaying,
	},

@pancsta pancsta merged commit 88ef244 into main Feb 22, 2024
2 checks passed
@pancsta pancsta deleted the feat/state-groups-remove-rel branch February 22, 2024 14:20
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.

None yet

1 participant