Skip to content

When a polymer element is already imported, importHref does not fire the ok function #55

@TipzCM

Description

@TipzCM

In Polymer.java:

public static void importHref(String hrefOrTag, final Function ok, final Function err) {
    final String href = absoluteHref(hrefOrTag);
    if (!urlImported.contains(href)) {
        urlImported.add(href);
        whenPolymerLoaded(new Function() {
            public Object call(Object arg) {
                Base.importHref(href, ok, err);
                return null;
            }
        });
    }
}

The problem i see is that if urlImported already has the imported elements, the ok function is not fired, necessitating a manual check for the element (essentially isRegistered, which is private).

Or maybe i'm going about this all wrong. How do i know if a polymer element has been imported into gwt?

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions