Jump to content
Search Community

Missing Plugin Error with gsap.set(... {clearProps: "transform"})

Eunomiac test
Moderator Tag

Recommended Posts

The following effect ...

gsap.registerEffect({
  name: "brighten",
  effect: (targets, config) => gsap.to(targets, {
    color: C.html.colors.fgBright,
    scale: 1.25,
    duration: config.duration,
    onReverseComplete() { gsap.set(this.targets, {clearProps: "transform"}) }
  }),
  defaults: {duration: 0.25},
  extendTimeline: true
}

... results in the following console error when run:

gsap-core.js:84 Invalid property clearProps set to transform Missing plugin? gsap.registerPlugin()
  _missingPlugin	   @ gsap-core.js:84
  _addPropTween		   @ gsap-core.js:2644
  _initTween		   @ gsap-core.js:2819
  _attemptInitTween	   @ gsap-core.js:433
  _renderZeroDurationTween @ gsap-core.js:469
  render		   @ gsap-core.js:3030
  Tween			   @ gsap-core.js:3004
  set			   @ gsap-core.js:3277

I've copied the gsap.set() syntax directly from the CSSPlugin docs which, as far as I understand, is integrated into gsap core and doesn't need to be registered (though I registered it anyways, to no avail).  Any insights as to why I'm getting this error and what I can do about it is, as always, very much appreciated!

 

(I didn't think a codepen demo was necessary for such a specific question, but please let me know if I should provide one!)

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...