{"_id":"@boshkov/ngx-lottie","_rev":"2-88285439e5bb4b7f56a3d0d00da86795","name":"@boshkov/ngx-lottie","dist-tags":{"latest":"6.1.1"},"versions":{"6.1.0":{"$schema":"../node_modules/ng-packagr/ng-package.schema.json","name":"@boshkov/ngx-lottie","version":"6.1.0","repository":{"type":"git","url":"git+https://github.com/codechem/ngx-lottie.git"},"license":"MIT","homepage":"https://github.com/codechem/ngx-lottie#readme","bugs":{"url":"git+https://github.com/codechem/ngx-lottie/issues"},"keywords":["animation","canvas","svg","after effects","plugin","angular","angular8","angular 8","angular 9","universal","ivy"],"sideEffects":true,"peerDependencies":{"@angular/core":">=8.0.0","lottie-web":">=5.4.0","rxjs":">=6.0.0","tslib":"^1.10.0"},"main":"bundles/ngx-lottie.umd.js","module":"fesm5/ngx-lottie.js","es2015":"fesm2015/ngx-lottie.js","esm5":"esm5/ngx-lottie.js","esm2015":"esm2015/ngx-lottie.js","fesm5":"fesm5/ngx-lottie.js","fesm2015":"fesm2015/ngx-lottie.js","typings":"ngx-lottie.d.ts","metadata":"ngx-lottie.metadata.json","description":"<h1 align=\"center\">\r   <img src=\"https://raw.githubusercontent.com/ngx-lottie/ngx-lottie/master/docs/assets/lottie.gif\">\r </h1>","_id":"@boshkov/ngx-lottie@6.1.0","_npmVersion":"6.4.1","_nodeVersion":"10.15.3","_npmUser":{"name":"boshkov","email":"ilija.boshkov@gmail.com"},"dist":{"integrity":"sha512-xX2h2+59oTBoBHC3JL0S3WlexY/MVEeDp2QEM/M11Hkp52P/Q5mMmVO169KBQvsrskoNZd6NhI5L6e3cOTHm0g==","shasum":"7de556ed4a1d57b87da8db97d7d22ed6e916ff72","tarball":"https://registry.npmjs.org/@boshkov/ngx-lottie/-/ngx-lottie-6.1.0.tgz","fileCount":78,"unpackedSize":532725,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.4\r\nComment: https://openpgpjs.org\r\n\r\nwsFcBAEBCAAQBQJezN3/CRA9TVsSAnZWagAAzUkP/36hJreby1rbb21RRNMR\nMD5TmtqPeJflDXAl22GAShIUna+I0fJQxei1Y3hwJrbVtV+oikAU0CchGTqt\nHVi902ll++tNuBlj+n2NfBw6xikAwLHHPodeNxsY223CdQPUmnZZCC5s2Jgt\npcmFvt7le6RkOlT2Ctn2qmIqWoMD6fGE+lNI30AqdMB3KPY0tJC3Os44RO7r\n46YWQtXxxf+1g06iv03GyirkJTpanYbd7c7LfJlxGilXmJOJYzj514Z2KqDq\nzCbi70Pz6wsEPc75GXPATUqDmoGukD16vsFQgnolaIv9ECtFi/T3REFZ+zNH\nB2wCIaHFDEaEMo+2Zz3eL+bfDtQKgmS41Vow+/HolVZ7hoTqqx57oxK7Lsub\n720f0guNuD0bLa2ZOe/ltGAsmdVX2wAht3UozzXATg5ySS24ADK+TXwRrCcj\n1sV7VuQYJjPjyFV0V6E9yBo4K2wJ4lXXN11qPj89F/a2hp1+DSob36JkWsUG\nvG50Q3ueheS1NFnaqGK5iSJn8FbcfWFn1miOn2gKncnE0PZjjUXuGrHiHvTM\nBhbgDj/xXhx+dd3J92cqn7Ub4uPWKQnwIdyvWMW//FStfZlvsE6P4x9F6TMv\nrcci/M+fHX5WVoTfrJdsG6QpdhafUjk5/53kSFQjQDJ8v7NSbSqhKUkacqWm\ny01F\r\n=60uK\r\n-----END PGP SIGNATURE-----\r\n","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEYCIQDYtWBhFBVfdFnNpL7mh2PrfroCJrSWh8uyF4xeqmCiZwIhANQ1ldK+9N3gJS6Fzg/g69I/j+Kfb2D4lrGUfWJSXEQd"}]},"maintainers":[{"name":"boshkov","email":"ilija.boshkov@gmail.com"}],"directories":{},"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/ngx-lottie_6.1.0_1590484479491_0.2094445106999583"},"_hasShrinkwrap":false},"6.1.1":{"$schema":"../node_modules/ng-packagr/ng-package.schema.json","name":"@boshkov/ngx-lottie","version":"6.1.1","repository":{"type":"git","url":"git+https://github.com/codechem/ngx-lottie.git"},"license":"MIT","homepage":"https://github.com/codechem/ngx-lottie#readme","bugs":{"url":"git+https://github.com/codechem/ngx-lottie/issues"},"keywords":["animation","canvas","svg","after effects","plugin","angular","angular8","angular 8","angular 9","universal","ivy"],"sideEffects":true,"peerDependencies":{"@angular/core":">=8.0.0","lottie-web":">=5.6.10","rxjs":">=6.0.0","tslib":"^1.10.0"},"main":"bundles/ngx-lottie.umd.js","module":"fesm5/ngx-lottie.js","es2015":"fesm2015/ngx-lottie.js","esm5":"esm5/ngx-lottie.js","esm2015":"esm2015/ngx-lottie.js","fesm5":"fesm5/ngx-lottie.js","fesm2015":"fesm2015/ngx-lottie.js","typings":"ngx-lottie.d.ts","metadata":"ngx-lottie.metadata.json","description":"<h1 align=\"center\">\r   <img src=\"https://raw.githubusercontent.com/ngx-lottie/ngx-lottie/master/docs/assets/lottie.gif\">\r </h1>","_id":"@boshkov/ngx-lottie@6.1.1","_npmVersion":"6.4.1","_nodeVersion":"10.15.3","_npmUser":{"name":"boshkov","email":"ilija.boshkov@gmail.com"},"dist":{"integrity":"sha512-VZyUbsdVa88NV7Zi+EJkPwICtu3xPdCZE0q612PthiIQEefzMbjBaGCKD9+qa98TSl/CzRVEBj2DzNEDLepn6g==","shasum":"dfb951970a8e1fc2e56074e8ea4d8c19736ab4e8","tarball":"https://registry.npmjs.org/@boshkov/ngx-lottie/-/ngx-lottie-6.1.1.tgz","fileCount":78,"unpackedSize":532726,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.4\r\nComment: https://openpgpjs.org\r\n\r\nwsFcBAEBCAAQBQJezO/bCRA9TVsSAnZWagAAdgUP/2VxgwCQYUfk4xBmzm1Y\nXzrefhCG7PXjZpAWOtWiOaZX4okBaZM7/RCYD1roxTQIvHmBLgVoLGku2Oq9\nojUb2qKXwY4jFwo2zLLyOmjBX/j3HEJy9VElbEEaoZzgqLDoXBVKGBPBC31o\nnZk6rEPBnt4C2BM20tcRnb9sZEdLIF7lp54phudPnKu6L18Jg7xhLDCjCmAf\nRHGtsI66hx0tpcyYVaShj9Zc5NL2wANbdK6REaaI04HEWpYhrbTQWG+LqO+k\nrIcPnumQZ1oe5lD0/iC+WiO2sSy4/bG5S89MFadTlrDC7XWTQZvvSO1oD2M6\n8tR6BUHpC8LE5MkrlM0pl6AcuUAQF8SAC5+sc6F1zQul/XCa7Ge4dWef/gyx\n/1vnQfGhqukQ/GTrw5vx3E6XRKq0MHHMZR8UJPyPxuAH+67NI5oPY/aTAUCh\nBvrx/cWragj/U/18siuKZ8qpS5uj++1GB5Ce79dvbghJZDNKtVOhdpjp5Egc\nYam0IT3Gl6DoVGxHjazWqk0I+hnD+fs32XwocGv/2WCR7bMhHiV985Gv8vQ2\nDTFYEPXkVhHhEhRxlFcGzHIvhlgpWVxFgT/ZTq8/n47esWCJoVcmbcqqowfF\nX7ZsbCIP8YBRYco3pCF2vydRgaYCTAa9dA3uo5MbzGfQKguqGkJywWUVD4QO\nqQE0\r\n=p7ON\r\n-----END PGP SIGNATURE-----\r\n","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIQCjTKL6dDf3VgKuyZDHrQXeUqcn2+kjI/sm1+yMv45ZvwIgarXIOwy9qm0JfrbLpmpXL31bgY0PjpveZQMObW7puUM="}]},"maintainers":[{"name":"boshkov","email":"ilija.boshkov@gmail.com"}],"directories":{},"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/ngx-lottie_6.1.1_1590489050748_0.9062217240495967"},"_hasShrinkwrap":false}},"time":{"created":"2020-05-26T09:14:39.442Z","6.1.0":"2020-05-26T09:14:39.623Z","modified":"2022-04-04T20:13:25.295Z","6.1.1":"2020-05-26T10:30:51.035Z"},"maintainers":[{"name":"boshkov","email":"ilija.boshkov@gmail.com"}],"description":"<h1 align=\"center\">\r   <img src=\"https://raw.githubusercontent.com/ngx-lottie/ngx-lottie/master/docs/assets/lottie.gif\">\r </h1>","homepage":"https://github.com/codechem/ngx-lottie#readme","keywords":["animation","canvas","svg","after effects","plugin","angular","angular8","angular 8","angular 9","universal","ivy"],"repository":{"type":"git","url":"git+https://github.com/codechem/ngx-lottie.git"},"bugs":{"url":"git+https://github.com/codechem/ngx-lottie/issues"},"license":"MIT","readme":"<h1 align=\"center\">\r\n  <img src=\"https://raw.githubusercontent.com/ngx-lottie/ngx-lottie/master/docs/assets/lottie.gif\">\r\n</h1>\r\n\r\n<div align=\"center\">\r\n  <strong>A minimal customizable performance-stable Angular component for rendering After Effects animations. Compatible with Angular 9+.</strong>\r\n</div>\r\n\r\n<br/>\r\n\r\n<div align=\"center\">\r\n  <!-- CircleCI -->\r\n  <a href=\"https://circleci.com/gh/ngx-lottie/ngx-lottie/tree/master\">\r\n    <img src=\"https://circleci.com/gh/ngx-lottie/ngx-lottie/tree/master.svg?style=svg\" alt=\"CircleCI\">\r\n  </a>\r\n\r\n  <!-- License -->\r\n  <a href=\"https://github.com/ngx-lottie/ngx-lottie/blob/master/LICENSE\">\r\n    <img src=\"https://img.shields.io/badge/License-MIT-brightgreen.svg\" alt=\"Licence: MIT\">\r\n  </a>\r\n\r\n  <!-- Package -->\r\n  <a href=\"https://www.npmjs.com/package/ngx-lottie\">\r\n    <img src=\"https://badge.fury.io/js/ngx-lottie.svg\" alt=\"npm version\" height=\"18\">\r\n  </a>\r\n\r\n  <!-- Dependecies -->\r\n  <img alt=\"David\" src=\"https://img.shields.io/david/ngx-lottie/ngx-lottie.svg\">\r\n</div>\r\n\r\n## Table of contents\r\n\r\n- [Features](#features)\r\n- [Quick example](#quick-example)\r\n- [Installation](#installation)\r\n- [Usage](#usage)\r\n- [Caching](#caching)\r\n- [API](#api)\r\n- [Optimizations](#optimizations)\r\n- [Server side rendering](#server-side-rendering)\r\n\r\n## Features\r\n\r\n- **rich:** `ngx-lottie` provides more opportunities to work with API exposed by Lottie\r\n- **strict:** all types of objects and events are available to you\r\n- **performant:** the `lottie-web` library can be loaded synchronously or on demand\r\n\r\n## Quick example\r\n\r\n```html\r\n<ng-lottie\r\n  width=\"600px\"\r\n  height=\"500px\"\r\n  containerClass=\"moving-box another-class\"\r\n  [styles]=\"styles\"\r\n  [options]=\"options\"\r\n  (animationCreated)=\"animationCreated($event)\"\r\n  (configReady)=\"configReady()\"\r\n  (dataReady)=\"dataReady()\"\r\n  (domLoaded)=\"domLoaded()\"\r\n  (enterFrame)=\"enterFrame($event)\"\r\n  (segmentStart)=\"segmentStart($event)\"\r\n  (complete)=\"complete($event)\"\r\n  (loopComplete)=\"loopComplete($event)\"\r\n  (destroy)=\"destroy($event)\"\r\n  (error)=\"error($event)\"\r\n></ng-lottie>\r\n```\r\n\r\n## Installation\r\n\r\nTo install `ngx-lottie` run the following command:\r\n\r\n```bash\r\nnpm i lottie-web ngx-lottie\r\n# Or if you use yarn\r\nyarn add lottie-web ngx-lottie\r\n```\r\n\r\n## Usage\r\n\r\nFirst, import the `LottieModule` into the `AppModule`:\r\n\r\n```typescript\r\nimport { NgModule } from '@angular/core';\r\nimport { LottieModule } from 'ngx-lottie';\r\nimport player from 'lottie-web';\r\n\r\n// Note we need a separate function as it's required\r\n// by the AOT compiler.\r\nexport function playerFactory() {\r\n  return player;\r\n}\r\n\r\n@NgModule({\r\n  imports: [LottieModule.forRoot({ player: playerFactory })],\r\n})\r\nexport class AppModule {}\r\n```\r\n\r\nThe `lottie-web` library can be loaded on demand using dynamic import. Webpack will load this library only when your animation gets rendered for the first time. Given the following code:\r\n\r\n```ts\r\nimport { NgModule } from '@angular/core';\r\nimport { LottieModule } from 'ngx-lottie';\r\n\r\nexport function playerFactory() {\r\n  return import('lottie-web');\r\n}\r\n\r\n@NgModule({\r\n  imports: [LottieModule.forRoot({ player: playerFactory })],\r\n})\r\nexport class AppModule {}\r\n```\r\n\r\nNow you can simply use the `ng-lottie` component and provide your custom options via the `options` binding:\r\n\r\n```typescript\r\nimport { Component } from '@angular/core';\r\nimport { AnimationItem } from 'lottie-web';\r\nimport { AnimationOptions } from 'ngx-lottie';\r\n\r\n@Component({\r\n  selector: 'app-root',\r\n  template: `\r\n    <ng-lottie [options]=\"options\" (animationCreated)=\"animationCreated($event)\"></ng-lottie>\r\n  `,\r\n})\r\nexport class AppComponent {\r\n  options: AnimationOptions = {\r\n    path: '/assets/animation.json',\r\n  };\r\n\r\n  animationCreated(animationItem: AnimationItem): void {\r\n    console.log(animationItem);\r\n  }\r\n}\r\n```\r\n\r\nAlso it's possible to use the `lottie` directive if you'd like to provide your own custom container and control it:\r\n\r\n```typescript\r\nimport { Component } from '@angular/core';\r\nimport { AnimationItem } from 'lottie-web';\r\nimport { AnimationOptions } from 'ngx-lottie';\r\n\r\n@Component({\r\n  selector: 'app-root',\r\n  template: `\r\n    <main lottie [options]=\"options\" (animationCreated)=\"animationCreated($event)\"></main>\r\n  `,\r\n})\r\nexport class AppComponent {\r\n  options: AnimationOptions = {\r\n    path: '/assets/animation.json',\r\n  };\r\n\r\n  animationCreated(animationItem: AnimationItem): void {\r\n    console.log(animationItem);\r\n  }\r\n}\r\n```\r\n\r\nNotice that you will need to import the `LottieModule` into other modules as it exports `ng-lottie` component and `lottie` directive. But `forRoot` has to be called only once!\r\n\r\n## Caching\r\n\r\n`lottie-web` will load your JSON file every time when animation is created. When importing the `LottieModule` into the root module you can provide the `useCache` option:\r\n\r\n```ts\r\nimport { NgModule } from '@angular/core';\r\nimport { LottieModule } from 'ngx-lottie';\r\n\r\nexport function playerFactory() {\r\n  return import('lottie-web');\r\n}\r\n\r\n@NgModule({\r\n  imports: [\r\n    LottieModule.forRoot({\r\n      player: playerFactory,\r\n      useCache: true,\r\n    }),\r\n  ],\r\n})\r\nexport class AppModule {}\r\n```\r\n\r\nThis will enable cache under the hood. Since the cache is enabled your JSON file will be loaded only once.\r\n\r\n## API\r\n\r\n### Bindings\r\n\r\nThe `ng-lottie` component supports the following bindings:\r\n\r\n```ts\r\n@Component({\r\n  selector: 'app-root',\r\n  template: `\r\n    <ng-lottie\r\n      width=\"500px\"\r\n      height=\"600px\"\r\n      containerClass=\"moving-box\"\r\n      [styles]=\"styles\"\r\n      [options]=\"options\"\r\n    ></ng-lottie>\r\n  `,\r\n})\r\nexport class AppComponent {\r\n  options: AnimationOptions = {\r\n    path: '/assets/animation.json',\r\n  };\r\n\r\n  styles: Partial<CSSStyleDeclaration> = {\r\n    maxWidth: '500px',\r\n    margin: '0 auto',\r\n  };\r\n}\r\n```\r\n\r\n- `options: AnimationOptions` options used by `AnimationItem`\r\n- `width?: string` container element width in pixels. Bound to `[style.width]`. You can provide any CSS unit, e.g. `100em`\r\n- `height?: string` container element height in pixels. Bound to `[style.height]`. You can provide any CSS unit, e.g. `100em`\r\n- `styles?: Partial<CSSStyleDeclaration>` custom styles object. Bound to `[ngStyle]`\r\n- `containerClass?: string` custom container class(es). Bound to `[ngClass]`.\r\n\r\nThe `lottie` directive supports only `options` binding.\r\n\r\n### Events\r\n\r\n| @Output()        | Type                                            | Required | Description                                                                                                             |\r\n| ---------------- | ----------------------------------------------- | -------- | ----------------------------------------------------------------------------------------------------------------------- |\r\n| animationCreated | `AnimationItem`                                 | optional | Dispatched after the `lottie` successfully creates animation                                                            |\r\n| configReady      | `void`                                          | optional | Dispatched after the needed renderer is configured                                                                      |\r\n| dataReady        | `void`                                          | optional | Dispatched when all parts of the animation have been loaded                                                             |\r\n| domLoaded        | `void`                                          | optional | Dispatched when elements have been added to the DOM                                                                     |\r\n| enterFrame       | `BMEnterFrameEvent`                             | optional | Dispatched after entering the new frame                                                                                 |\r\n| segmentStart     | `BMSegmentStartEvent`                           | optional | Dispatched when the new segment is adjusted                                                                             |\r\n| loopComplete     | `BMCompleteLoopEvent`                           | optional | Dispatched after completing frame loop                                                                                  |\r\n| complete         | `BMCompleteEvent`                               | optional | Dispatched after completing the last frame                                                                              |\r\n| destroy          | `BMDestroyEvent`                                | optional | Dispatched in the `ngOnDestroy` hook of the service that manages `lottie`'s events, it's useful for releasing resources |\r\n| error            | `BMRenderFrameErrorEvent OR BMConfigErrorEvent` | optional | Dispatched if the lottie player could not render some frame or parse the config                                         |\r\n\r\n## Optimizations\r\n\r\nThe `ng-lottie` component is marked with `OnPush` change detection strategy. This means it will not be checked in any phase of the change detection mechanism until you change the reference to some binding. For example if you use an `svg` renderer and there are a lot DOM elements projected — you would like to avoid checking this component, as it's not necessary.\r\n\r\n`AnimationItem` events are listened outside of the Angular zone. You shouldn't worry that animation events will cause change detection every ms.\r\n\r\n**But be careful!** Always wrap any calls to `AnimationItem` methods in `runOutsideAngular`. See the below code:\r\n\r\n```ts\r\nimport { Component, NgZone } from '@angular/core';\r\nimport { AnimationItem } from 'lottie-web';\r\nimport { AnimationOptions } from 'ngx-lottie';\r\n\r\n@Component({\r\n  selector: 'app-root',\r\n  template: `\r\n    <ng-lottie [options]=\"options\" (animationCreated)=\"animationCreated($event)\"></ng-lottie>\r\n\r\n    <button (click)=\"stop()\">Stop</button>\r\n    <button (click)=\"play()\">Play</button>\r\n  `,\r\n})\r\nexport class AppComponent {\r\n  options: AnimationOptions = {\r\n    path: '/assets/animation.json',\r\n  };\r\n\r\n  private animationItem: AnimationItem;\r\n\r\n  constructor(private ngZone: NgZone) {}\r\n\r\n  animationCreated(animationItem: AnimationItem): void {\r\n    this.animationItem = animationItem;\r\n  }\r\n\r\n  stop(): void {\r\n    this.ngZone.runOutsideAngular(() => this.animationItem.stop());\r\n  }\r\n\r\n  play(): void {\r\n    this.ngZone.runOutsideAngular(() => this.animationItem.play());\r\n  }\r\n}\r\n```\r\n\r\n## Server side rendering\r\n\r\nBy default, `lottie` will load your `json` file with animation data every time you create an animation. You may have some problems with the connection, so there may be some delay or even timeout. It's worth loading animation data only once and cache it on the client side, so every time you create an animation — the animation data will be retrieved from cache.\r\n\r\n`ngx-lottie/server` package gives you the opportunity to preload animation data and cache it using `TransferState`.\r\n\r\n### How2?\r\n\r\nTL;DR - see `integration` folder.\r\n\r\nImport the `LottieServerModule` into your `AppServerModule`:\r\n\r\n```typescript\r\nimport { NgModule } from '@angular/core';\r\nimport { ServerModule, ServerTransferStateModule } from '@angular/platform-server';\r\nimport { LottieServerModule } from 'ngx-lottie/server';\r\n\r\nimport { AppModule } from './app.module';\r\nimport { AppComponent } from './app.component';\r\n\r\n@NgModule({\r\n  imports: [\r\n    // `AppModule` first as you know\r\n    AppModule,\r\n    ServerModule,\r\n    ServerTransferStateModule,\r\n    LottieServerModule.forRoot({\r\n      preloadAnimations: {\r\n        folder: 'dist/assets',\r\n        animations: ['data.json'],\r\n      },\r\n    }),\r\n  ],\r\n  bootstrap: [AppComponent],\r\n})\r\nexport class AppServerModule {}\r\n```\r\n\r\nDon't forget to import `BrowserTransferStateModule` into your `AppModule`. Let's look at these options. `animations` is an array of `json` files, that contain animation data, that should be read on the server side, cached and transfered on the client. `folder` is a path where your `json` files are located, but you should use it properly, this path is joined with the `process.cwd()`. Imagine such project structure:\r\n\r\n```\r\n— dist (here you store your output artifacts)\r\n  — project-name\r\n    — assets\r\n    — index.html\r\n    — main.hash.js\r\n— dist-server\r\n  — server.js\r\n— src (here is your app)\r\n— angular.json\r\n— package.json\r\n— webpack.config.js\r\n```\r\n\r\nIf you start a server from the root folder like `node dist-server/server`, thus the `folder` property should equal `dist/project-name/assets`.\r\n\r\nAfter installing `LottieServerModule` - now you have to import `LottieTransferState` from the `ngx-lottie` package. Don't worry, this service is tree-shakable and won't be bundled if you don't inject it anywhere.\r\n\r\nInject this service into your component where you declare animation options:\r\n\r\n```typescript\r\nimport { Component } from '@angular/core';\r\nimport { AnimationOptions, LottieTransferState } from 'ngx-lottie';\r\n\r\n@Component({\r\n  selector: 'app-root',\r\n  template: `\r\n    <ng-lottie [options]=\"options\"></ng-lottie>\r\n  `,\r\n})\r\nexport class AppComponent {\r\n  options: AnimationOptions = {\r\n    animationData: this.lottieTransferState.get('data.json'),\r\n  };\r\n\r\n  constructor(private lottieTransferState: LottieTransferState) {}\r\n}\r\n```\r\n\r\nNotice, `data.json` is a filename that you pass to the `preloadAnimations.animations` property. Finally change this:\r\n\r\n```typescript\r\nplatformBrowserDynamic().bootstrapModule(AppModule);\r\n```\r\n\r\nTo this:\r\n\r\n```typescript\r\ndocument.addEventListener('DOMContentLoaded', () => {\r\n  platformBrowserDynamic().bootstrapModule(AppModule);\r\n});\r\n```\r\n","readmeFilename":"README.md"}