UNPKG

947 BTypeScriptView Raw
1/**
2 Returns a promise which will resolve when rendering has completed. In
3 this context, rendering is completed when all auto-tracked state that is
4 consumed in the template (including any tracked state in models, services,
5 etc. that are then used in a template) has been updated in the DOM.
6
7 For example, in a test you might want to update some tracked state and
8 then run some assertions after rendering has completed. You _could_ use
9 `await settled()` in that location, but in some contexts you don't want to
10 wait for full settledness (which includes test waiters, pending AJAX/fetch,
11 run loops, etc) but instead only want to know when that updated value has
12 been rendered in the DOM. **THAT** is what `await rerender()` is _perfect_
13 for.
14 @public
15 @returns {Promise<void>} a promise which fulfills when rendering has completed
16*/
17export default function rerender(): Promise<void>;
18//# sourceMappingURL=rerender.d.ts.map
\No newline at end of file