perf(ivy): avoid repeated native node retrieval and patching (#33322)

Before this change instantiating multiple directives on the same
host node would result in repeated RNode retrieval and patching.
This commint re-organises code around directive instance creation
so the host node processing (common to all directives) happens
once and only once.

As the additional benefit the directive instantiation logic gets
centralised in one function (at the expense of patching logic
duplication for root node).

PR Close #33322
This commit is contained in:
Pawel Kozlowski
2019-10-21 10:38:21 +02:00
committed by atscott
parent 2c208f98a9
commit 41caafcaf2
3 changed files with 18 additions and 36 deletions

View File

@ -392,9 +392,6 @@
{
"name": "noSideEffects"
},
{
"name": "postProcessBaseDirective"
},
{
"name": "refreshChildComponents"
},

View File

@ -1088,12 +1088,6 @@
{
"name": "patchConfig"
},
{
"name": "postProcessBaseDirective"
},
{
"name": "postProcessDirective"
},
{
"name": "readPatchedData"
},