Merge pull request #128 from microsoft/useRequestAnimationFrameInsteadOfSetTimeout
use requestAnimationFrame instead of setTimeOut
This commit is contained in:
Коммит
7845d52e4a
|
@ -1,7 +1,7 @@
|
|||
{
|
||||
"$schema": "../../node_modules/ng-packagr/package.schema.json",
|
||||
"name": "@angular-react/core",
|
||||
"version": "1.0.0-next",
|
||||
"version": "1.0.1",
|
||||
"ngPackage": {
|
||||
"deleteDestPath": true,
|
||||
"whitelistedNonPeerDependencies": [
|
||||
|
|
|
@ -250,7 +250,7 @@ export abstract class ReactWrapperComponent<TProps extends {}> implements AfterC
|
|||
const nativeElement = this.elementRef.nativeElement;
|
||||
|
||||
// We want to wait until child elements are rendered
|
||||
afterRenderFinished(() => {
|
||||
requestAnimationFrame(() => {
|
||||
if (nativeElement.firstElementChild) {
|
||||
const rootChildDisplay = getComputedStyle(nativeElement.firstElementChild).display;
|
||||
nativeElement.style.display = rootChildDisplay;
|
||||
|
|
|
@ -1,7 +1,7 @@
|
|||
{
|
||||
"$schema": "../../node_modules/ng-packagr/package.schema.json",
|
||||
"name": "@angular-react/fabric",
|
||||
"version": "1.0.0-next",
|
||||
"version": "1.0.1",
|
||||
"ngPackage": {
|
||||
"lib": {
|
||||
"entryFile": "public-api.ts",
|
||||
|
|
Загрузка…
Ссылка в новой задаче