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

Consistent node type behavior regarding property unset and child node unset #4722

Open
mhsdesign opened this issue Nov 10, 2023 · 1 comment
Labels
9.0 Backlog A category for things that are okay to be rather 'hidden' I: Discussion‌‌

Comments

@mhsdesign
Copy link
Member

As shown here (by the new tests) #4620 node property unset via ~ does not work but is silently ignored.

Some.NodeType:
  superTypes:
    Some.SuperNodeType: true
  properties:
    inheritedProperty: ~ # noop

instead its only possible to change the type or set it to hidden. A shortcut for this would be:

Some.NodeType:
  superTypes:
    Some.SuperNodeType: true
  properties:
    inheritedProperty: {}

see #4620 (comment) we are not sure if we like that one can change the type of a property or disable it in the inspector but its possible.


in contraire, unsetting a child node is allowed:

Some.NodeType:
  superTypes:
    Some.SuperNodeType: true
  childNodes:
    main: ~
@mhsdesign
Copy link
Member Author

me and @kitsunet discussed in the weekly that unsetting to null should in both cases throw an error.

about changing property types: i guess it would be cool to only allow type narrowing but i guess this is out of scope.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
9.0 Backlog A category for things that are okay to be rather 'hidden' I: Discussion‌‌
Projects
None yet
Development

No branches or pull requests

3 participants