stencilproject/Stencil

@Prop with type of an interface ends up in an typescript error

LutzStrobel opened this issue · 2 comments

I have an interface like that:
export default interface PostRecord{
...
}

and a component like this:

export class Container implements ComponentInterface {

@prop record: PostRecord;

...
}
with a correct import of PostRecord.
Then the typescript compiler complains:
[ ERROR ] TypeScript: ./src/components.d.ts:29:19
[0] Cannot find name 'PostRecord'.
[0]
[0] L28: "active": boolean;
[0] L29: "record": PostRecord;
[0] L30: }

Is it possible to use interface types as property types or what is wrong with the picture?
Thank you for your help.
Lutz

Hi @LutzStrobel. I think you posted to the wrong repo?

Really, the wrong repo.
Thanx