Skip to content

add component-laid-out lifecycle callback #434

Description

@Andersmholmgren

When working with layout managers like polymer-layout, polymer-grid-layout etc it is often important to know when the component has finished being layout out. For example, if the component contains a canvas element that needs to be resized based on the containing element this needs to happen when the containing element has it's size set on completion of the layout.

polymer-grid-layout has it's own event that it fires as polymer-layout may soon but this requires use of the signal mechanism at this stage. These, whilst useful, seem somewhat adhoc, given this is IMO a key lifecycle event for a component

Activity

  1. changed the title [-]add component laid out lifecycle callback[/-] [+]add component-layed-out lifecycle callback[/+] on Aug 18, 2014
  2. changed the title [-]add component-layed-out lifecycle callback[/-] [+]add component-laid-out lifecycle callback[/+] on Aug 18, 2014
  3. sjmiles commented on Aug 18, 2014

    @sjmiles
    Contributor

    As of now this is something to solve at a component or component-set level. There is no clear mandate today for what this would mean more generally.

    This is not an inherently bad idea, but I think we need to let it rise again later.

  4. Andersmholmgren commented on Aug 24, 2014

    @Andersmholmgren
    Author

    I'm updating my dart polymer app to the latest polymer, core-elements and paper-elements. I was previously using using polymer-elements and in that polymer-layout had a on-polymer-layout event that I was using to help size a canvas element to take the entire size of it's container (see http://stackoverflow.com/questions/21816467/autosizing-canvas-inside-a-polymer-grid-layout).

    I can't find an equivalent int core-elements so I'm back to square one. How do I handle this now?

    See also http://stackoverflow.com/questions/22111447/there-doesnt-seem-to-be-a-polymer-layout-event

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Type

No type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions