Jump to content
GreenSock

Search In
  • More options...
Find results that contain...
Find results in...
goodcontext

There's a strange problem.

Go to solution Solved by Cassie,

Recommended Posts

There is an error like a screenshot.
I wondered why this error occurred, so I pressed Ctrl-Z in the visual studio code and returned it to its original state, where there was no problem.

And yet the error is still there. I don't think I recovered 100% because I had to press Ctrl+Z a lot. I cannot recover to Ctrl-Z at this time.

I rebooted because I thought it was a PC problem.
I tested the AVAST vaccine because I thought it was a virus problem, but there was no virus.
I get the same error message when I try to access the web from another PC.
So I don't think it's a PC problem.
I think I did something wrong, but I don't know what it is.

I thought it was a typo, so I looked into HTML, css, and js files, but I couldn't find any problems.

I'd appreciate your help.

bug_report.jpg

 

It's a portfolio file for employment, should I upload the original? (CSS file and JS file are about 300 lines each. It's too much for others to analyze.) Or should I ask Club GreenSock Contact Us?

Link to comment
Share on other sites

I made a minimal demo.
There are only html files and js files, but there is no content, html has only the head part, and js file has only the register plugin part.
Nevertheless, when you press F12, the same error appears in your web browser.
All of the js files are the latest versions that have been downloaded. Why is this happening?

 

index.html

<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Test</title>
    <script src="js/jQuery.3.6.0.min.js"></script>
    <script src="js/imagesloaded.pkgd.min.js"></script>
    <script src="js/gsap-core.js"></script>
    <script src="js/ScrollTrigger.js"></script>
    <script src="js/ScrollSmoother.js"></script>
    <script src="js/script.js" defer></script>
</head>
<body>
    
</body>
</html>

script.js

gsap.registerPlugin(ScrollTrigger, ScrollSmoother);

Both Chrome and edge browsers have the same problem, and other PCs have the same problem.

Link to comment
Share on other sites

  • Solution

Hi there!

 

I deleted your demo because you were sharing the ScrollSmoother file and that's for members only. Please be careful not to share that publicly, (including public github repos) thanks!

It looks like you're using the UMD or ESM files, these are set up to work with some fancy build tooling, which you're not using. You can just use the minified files instead. (In the minified folder)

Let me know if you get stuck or if that's not enough info.
 

  • Like 2
Link to comment
Share on other sites

Thank you for your answer.
I was waiting for a few minutes to answer yesterday, and I just slept because it was dawn.
I didn't think I had to manage the ScrollSmoother file.
I'm sorry for my carelessness.
And thank you for deleting the file.

Originally, I used a minimal file, but I thought it would be better to see the number of file lines in the error message, so I replaced it with an ESM file, but I didn't know if I would create a new error message.
The error has just been resolved. Error caused by incorrect class name specified by querySelector.
I expected it to be a typo because I changed the class name a lot in the HTML file, but I couldn't find it yesterday because I was tired.
Thank you very much for your answer. Have a nice day.

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.
×