Skip to content

Refactored load() method to a Promise; updated expand/collapse API …#228

Merged
texodus merged 1 commit intomasterfrom
async-load
Sep 4, 2018
Merged

Refactored load() method to a Promise; updated expand/collapse API …#228
texodus merged 1 commit intomasterfrom
async-load

Conversation

@texodus
Copy link
Member

@texodus texodus commented Sep 4, 2018

…to be consistent.

This allows sane access to a <perspective-viewer>s view property, without timeout tricks, e.g.:

element.load(data).then(() => {
    element.view.collapse_to_depth(0);
    element.notifyResize();
});

@texodus texodus merged commit b15266b into master Sep 4, 2018
@texodus texodus deleted the async-load branch September 11, 2018 00:47
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Development

Successfully merging this pull request may close these issues.

1 participant