diff --git a/packages/vue3-lottie/README.md b/packages/vue3-lottie/README.md index 03c4a864..1a127992 100644 --- a/packages/vue3-lottie/README.md +++ b/packages/vue3-lottie/README.md @@ -200,6 +200,7 @@ More detailed explanations are provided in the [documentation](https://vue3-lott | backgroundColor | String | transparent | Background color of the container | | renderer | String | "svg" | Set the renderer | | rendererSettings | Object | {} | Options for if you want to use an existing canvas to draw (can be ignored on most cases) | +| assetsPath | String | '' | Set the assets path for the animation | # Events diff --git a/packages/vue3-lottie/src/vue3-lottie.vue b/packages/vue3-lottie/src/vue3-lottie.vue index b29937b7..ff1d560c 100644 --- a/packages/vue3-lottie/src/vue3-lottie.vue +++ b/packages/vue3-lottie/src/vue3-lottie.vue @@ -28,6 +28,7 @@ export interface LottieProps { playOnHover: boolean backgroundColor: string pauseAnimation: boolean + assetsPath: string } export default defineComponent({ @@ -100,6 +101,10 @@ export default defineComponent({ type: Object as PropType, default: () => ({}), }, + assetsPath: { + type: String as PropType, + default: '', + }, }, emits: { @@ -168,6 +173,7 @@ export default defineComponent({ loop: loop, autoplay: autoPlay, animationData: animationData, + assetsPath: props.assetsPath, } if (isEqual(props.rendererSettings, {}) === false) {