Hacker News new | past | comments | ask | show | jobs | submit login

This is what I feel is missing from web components. Some sort of generic api for components to reason about their immediate environment. Similar to the Unix OS pipes and filter api that means every program understands how to get some information about the context that it is being run in.

It's not difficult to imagine a calendar component that needs to visually display vastly differently depending on how much space it's parent gives it. Currently there is no generic way to solve this.




> It's not difficult to imagine a calendar component that needs to visually display vastly differently depending on how much space it's parent gives it. Currently there is no generic way to solve this.

Maybe I'm being naive here, but isn't this solved really by getting the width of a block level element rendered by the Calendar component?

Yeah it does mean you need to get the width and then render everything else, but it's doable.




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: