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

nice-to-have: view extension support #632

Open
mcpride opened this issue Mar 18, 2024 · 2 comments
Open

nice-to-have: view extension support #632

mcpride opened this issue Mar 18, 2024 · 2 comments
Assignees
Labels
wanted New feature or request

Comments

@mcpride
Copy link

mcpride commented Mar 18, 2024

Great work, I like LikeC4! ;-)

It would be nice to have a possibility to also extend views equivalent to extending a model.

I have for example special actor role views like "Administrator role" in a large model. Different teams extend parts of that model in relation to their responsibility. It would be nice, that they could also extend these special role views in their area.

@davydkov davydkov added the wanted New feature or request label Mar 22, 2024
@jubr
Copy link

jubr commented Apr 15, 2024

@mcpride is this not already possible at #extend-views? Or do you mean something else?

Copy-paste:

views {
  view view1 {
    include *
  }
 
  view view2 extends view1 {
    title 'Same as View1, but with more details'
    style * {
      color muted
    }
    include some.backend
  }
 
  // cascade inheritance
  view view3 extends view2 {
    title 'Same as View2, but with more details'
    include * -> some.backend
  }
}

@mcpride
Copy link
Author

mcpride commented Apr 16, 2024

The view extends behavior is also interesting but it is a kind of inheritance and results in new views. The element extension behavior is more a kind of composition of parts. Would be nice to have the same for views.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
wanted New feature or request
Projects
None yet
Development

No branches or pull requests

3 participants