All IEnumerable<> projectable properties have to be marked as
[NotMapped] or EF throws an error. Example:
[Projectable]
public IEnumerable<MyThings> MySpecialThings => MyThings.Where(t => t.IsSpecial);
EF appears to be trying to map all properties defined as IEnumerable<> or ICollection<> as navigation properties, even if they are get-only (which, needless to say, includes properties like the above).
I could be convinced otherwise, but I would make the case that all projectable properties will always be unmapped.
It would be nice to have this library iterate through the models as part of model building and call .Ignore(theProjectableProperty)
All
IEnumerable<>
projectable properties have to be marked as[NotMapped]
or EF throws an error. Example:EF appears to be trying to map all properties defined as
IEnumerable<>
orICollection<>
as navigation properties, even if they are get-only (which, needless to say, includes properties like the above).I could be convinced otherwise, but I would make the case that all projectable properties will always be unmapped.
It would be nice to have this library iterate through the models as part of model building and call
.Ignore(theProjectableProperty)