I'm getting an error on the members-only DrawSVGPlugin when I deploy to Netlify.
I'm using Astro, which builds the site with Vite. Everything works fine on my local instance.
I've followed Greensock install instructions. Screenshot of my npmrc is attached.
I can see gsap and DrawSVGPlugin.js in /gsap in node_modules:
My script in Astro:
<script>
import { gsap } from "gsap";
import { DrawSVGPlugin } from "gsap/DrawSVGPlugin";
gsap.re
Can you run a build locally and preview then maybe show the error? Are you using a framework with Vite? Do you have a repository you could share? (make sure you don't have your auth exposed, read below)
You don't want to put your auth code for gsap right in your .npmrc as it would be public in your repo (same with .env never upload to your repo for build steps) so you use an env var on the server side like so.
package.json
"gsap": "npm:@gsap/shockingly@^3.11.1"