Lichay
Content Type
Profiles
Forums
Store
Blog
Product
Showcase
FAQ
Downloads
Posts posted by Lichay
-
-
so in code pen it work it no metter to me
This library doesn't support Angular 9 this is my case
-
2 minutes ago, GreenSock said:
I wish I could help, but without a reduced test case I'm afraid I can't do much. I have nothing to look at. Maybe it's a loading order thing, like your CSS isn't parsed by the browser yet? Very difficult for me to know.
do you want my git link?
-
17 minutes ago, GreenSock said:
It sounds like there is no ".cc::before" rule. Did you try to console.log(rule) before the tween?
Also, this is not valid:
gsap.to(rule, 3, { cssRule: { color: "#0000FF", x: 50 }, x: 300 });
You're telling the rule to animate x to 50....and you're ALSO telling GSAP to try to animate an "x" property directly on the rule object itself to 300 (without the help of CSSRulePlugin). I assume you didn't mean to leave that "x: 300" in that tween, right?
If you still need help, please provide a reduced test case (not just sample code). It's very difficult to troubleshoot blind, that's all. We have to guess at what else is going on in your project, what the context is like, etc. CodePen or codesandbox or something like that would be much better. Thanks!
why not I have a class with name cc
when i log in it say "undefined" for no reason
-
when I try to use gsap with pursue element it not recognize
that my ts
import { Component, OnInit } from '@angular/core'; import { gsap } from "gsap"; import { CSSRulePlugin } from "gsap/CSSRulePlugin"; import { ScrollTrigger } from "gsap/ScrollTrigger"; @Component({ selector: 'app-root', templateUrl: './app.component.html', styleUrls: ['./app.component.css'] }) export class AppComponent implements OnInit { title = 'gsapProject'; ngOnInit() { gsap.registerPlugin(CSSRulePlugin, ScrollTrigger); gsap.from('div h1', { scrollTrigger: 'div h1', y: 200, duration: 5 }); const rule = CSSRulePlugin.getRule('.cc::before'); gsap.to(rule, 3, { cssRule: { color: "#0000FF", x: 50 }, x: 300 }); } }
and this my HTML
<div> <h1 class="cc">new project</h1> </div>
Just try it with a new project for be clear and don't work .
This my message from the page
gsap-core.js:87 GSAP target undefined not found. https://greensock.com
feel like no way to do it.
pursue element at Angular 9
in GSAP
Posted
code pen it regular html css and javascript i don't use them i use framework and it don't work if i share with codepen it maybe work but so .. ? it bad .
everyone use framworks like me .
and with framwork this plug don't work as 'before' and 'after' like i said above