Quantcast
Channel: Ionic Forum - Latest topics
Viewing all articles
Browse latest Browse all 70752

GSAP DrawSVGPlugin

$
0
0

@AceBoy wrote:

Hello.
I want to implement this plugin in Ionic3 . As I know a npm package doesn’t have plugins from club, nor @types/gsap. I added DrawSVGPlugin.js into node_modules/gsap and later recreated an android platform.
In .ts file as import I tried:

import { DrawSVGPlugin } from "gsap/DrawSVGPlugin";

and as calling plugin:

TweenLite.to("#svg_1", 1, {drawSVG:"40% 60%", ease:Power1.easeInOut});

my html source of svg:

<svg xmlns:svg="http://www.w3.org/2000/svg" xmlns="http://www.w3.org/2000/svg" x="0px" y="0px" viewBox="0 0 100 100" preserveAspectRatio="none">
  <line stroke-linecap="undefined" stroke-linejoin="undefined" id="svg_1" y2="45.78805" x2="87.36405" y1="45.24458" x1="8.28813" stroke-width="12.5" stroke="#000" fill="none"/>
</svg>

Can anyone tell me what I am doing wrong? Or is there different way of doing it?

Posts: 1

Participants: 1

Read full topic


Viewing all articles
Browse latest Browse all 70752

Trending Articles