fix(ivy): ensure renderer begin/end methods are only called during change detection (#28192)
In VE the renderer.begin() and renderer.end() methods are only called when CD is called on an element. This patch ensures that Ivy does the same thing. Jira issue: FW-945 PR Close #28192
This commit is contained in:

committed by
Alex Rickabaugh

parent
1f7d3b9a57
commit
896cf35afb
@ -105,7 +105,7 @@ describe('renderer factory lifecycle', () => {
|
||||
|
||||
it('should work with a template', () => {
|
||||
renderToHtml(Template, {}, 1, 0, null, null, rendererFactory);
|
||||
expect(logs).toEqual(['create', 'begin', 'function create', 'function update', 'end']);
|
||||
expect(logs).toEqual(['create', 'function create', 'function update']);
|
||||
|
||||
logs = [];
|
||||
renderToHtml(Template, {});
|
||||
@ -115,8 +115,8 @@ describe('renderer factory lifecycle', () => {
|
||||
it('should work with a template which contains a component', () => {
|
||||
renderToHtml(TemplateWithComponent, {}, 2, 0, directives, null, rendererFactory);
|
||||
expect(logs).toEqual([
|
||||
'create', 'begin', 'function_with_component create', 'create', 'component create',
|
||||
'function_with_component update', 'component update', 'end'
|
||||
'create', 'function_with_component create', 'create', 'component create',
|
||||
'function_with_component update', 'component update'
|
||||
]);
|
||||
|
||||
logs = [];
|
||||
|
Reference in New Issue
Block a user