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

Fix and figure out how multiple properties should be represented #99

Open
kaleidawave opened this issue Dec 20, 2023 · 0 comments
Open
Assignees
Labels
checking Issues around checking needs-investigation Further information is requested

Comments

@kaleidawave
Copy link
Owner

Currently there is no difference in the representation of properties that are dependent once OR multiple times.

aka { [a: number]: "value" } has under a context properties as [(PropertyKey::Type(*number type*), Property::Value(TypeId -> Type::Constant(Constant::String("value")))]. There is no difference between this being a project with many keys that are number like OR a single key, which is of the type of number.

I think this can be solved by a separate variant Property on the RHS called Property::Multiple(Box<Property>) which denotes that the RHS property is dependent. This only makes sense if the LHS is PropertyKey::Type though 🤔. Also the RHS needs depend of types from the LHS for type mappings in TypeScript 🤔🤔

@kaleidawave kaleidawave added needs-investigation Further information is requested checking Issues around checking labels Dec 20, 2023
@kaleidawave kaleidawave self-assigned this Dec 20, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
checking Issues around checking needs-investigation Further information is requested
Projects
None yet
Development

No branches or pull requests

1 participant