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

Declarative application of decorators to a model manager #393

Closed
dselman opened this issue Mar 8, 2022 · 0 comments · Fixed by #395
Closed

Declarative application of decorators to a model manager #393

dselman opened this issue Mar 8, 2022 · 0 comments · Fixed by #395
Assignees

Comments

@dselman
Copy link
Contributor

dselman commented Mar 8, 2022

Feature Request 🛍️

Decorators are an important feature of models, however if models are heavily decorated, for a variety of purposes, then the models can become hard to read and maintain. It would be useful to be able to externalise decorators from the model and then to have them declaratively applied.

Use Case

We have a use case where we need to use models across various UX channels (web/mobile etc) and the models need to be decorated for display purposes.

Possible Solution

Define a new function decorateModels on ModelManager that takes a DecoratorCommandSet as input. The function traverse the model declarations and adds any decorators from the DecoratorCommandSet as necessary.

The DecoratorCommandSet defines a set of decorators that should be added to model elements.

Context

Trying to externalise decorators from models.

Detailed Description

TBD

@dselman dselman self-assigned this Mar 8, 2022
dselman added a commit that referenced this issue Mar 9, 2022
@dselman dselman linked a pull request Mar 9, 2022 that will close this issue
5 tasks
dselman added a commit that referenced this issue Mar 30, 2022
* feat: support for externalizing decorators #393
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 a pull request may close this issue.

1 participant