TheChris Posted July 10, 2022 Share Posted July 10, 2022 Hello, Last friday I joined the GreenSock club for the amazing tools. It took some time for me to figure it out but locally I have it running. I use it in combination with Sage/Bedrock. I added the following package to my project; "gsap": "npm:@gsap/shockingly", And I added the .npmrc file containing my token. As I said locally I have it running, I'm using the following plugins; import {gsap} from 'gsap'; import {ScrollTrigger} from 'gsap/ScrollTrigger'; import {ScrollSmoother} from 'gsap/ScrollSmoother'; import {SplitText} from 'gsap/SplitText'; gsap.registerPlugin(ScrollTrigger, ScrollSmoother, SplitText); Now that I can use ScrollSmoother I could get rid of Locomotive. But whenever I try to deploy my project to the server I run into this error; Error: https://npm.greensock.com/@gsap%2fshockingly/-/shockingly-3.10.4.tgz: Request failed "403 Forbidden" Which is strange because the .npmrc file containing my token is present in the root of my project. So has anyone an idea why this happens? More info in the logs; Arguments: /opt/nodejs/bin/node /usr/share/yarn/bin/yarn.js install --network-timeout 60000 PATH: /usr/local/cmb-git/lib/git-core:/data/sites/web/--mysite--//.local/bin:/usr/local/bin:/usr/bin:/bin Yarn version: 1.22.19 Node version: 16.15.1 Platform: linux x64 Trace: Error: https://npm.greensock.com/@gsap%2fshockingly/-/shockingly-3.10.4.tgz: Request failed "403 Forbidden" at ResponseError.ExtendableBuiltin (/usr/share/yarn/lib/cli.js:696:66) at new ResponseError (/usr/share/yarn/lib/cli.js:802:124) at Request.<anonymous> (/usr/share/yarn/lib/cli.js:66215:16) at Request.emit (node:events:527:28) at Request.module.exports.Request.onRequestResponse (/usr/share/yarn/lib/cli.js:141767:10) at ClientRequest.emit (node:events:527:28) at HTTPParser.parserOnIncomingClient (node:_http_client:631:27) at HTTPParser.parserOnHeadersComplete (node:_http_common:128:17) at TLSSocket.socketOnData (node:_http_client:494:22) at TLSSocket.emit (node:events:527:28) Link to comment Share on other sites More sharing options...
Cassie Posted July 10, 2022 Share Posted July 10, 2022 Hi there! Yarn is a bit of a tricky one sometimes. There's a known yarn issue with private npm repos. (nothing to do with GSAP - it's a yarn thing) Here's a thread discussing it And a demo repo using yarn and netlify https://github.com/prasannamestha/gsap-netlify-yarn I hope you manage to find the solution, pop back if this doesn't help! 2 Link to comment Share on other sites More sharing options...
TheChris Posted July 11, 2022 Author Share Posted July 11, 2022 Hi Cassie, Thanks for the reply. I think it's fixed now, I moved the .npmrc file to the themes folder in stead of the root of the WordPress installation folder. Thanks for the help! 1 Link to comment Share on other sites More sharing options...
Cassie Posted July 11, 2022 Share Posted July 11, 2022 Hooray! Glad you got it sorted Link to comment Share on other sites More sharing options...
Recommended Posts
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 accountSign in
Already have an account? Sign in here.
Sign In Now