Appreciation for the vanilla stuff. To add: If the scrollPercentage == 1, transition in a fillOpacity (from 0, set in the CSS, to 1, set in the JS) so it fills in at the end. To stop the initial transition when the page loads, you can add a .preload * { transition: none !important;} and a preload class to the body and remove that class on the window load.
Brilliant idea. Thanx. In browsers with "elastic scroll" ability, the scroll percentage may go out of range, like below zero and above 1. And it causes flickering when you reach the maximum scroll point. So after calculation the scrollPercentage value it should be trimmed like that: if (scrollPercentage1.0) scrollPercentage=1.0;
@@gknt7234 You right. My style is dictated by other scripting languages where there is some difference between integer and float types. It guarantees correct parsing in any case.
Great tutorial. I tend to use Vivus and also Vivus instant for general animated svgs but this is great especially as its used with vanilla JS, css and scroll percentages. Great job.
I love messing around with the SVG's to do some creative designs with. I have an extension that I use with VS Code called Svg Preview. When you have a svg file in VS Code the screen will split and show you the image. The image will update in real-time when making changes. 👍
Learned something new, thanks! Small nitpick btw, if you removed the style definition inside the SVG, might as well as remove the *cls-1* class of the ** :D
this really helps me because I was thinking of making this sort of handwriting letter reveal and I cant just do a simple reveal from left to right...I have to make sure the letters are written like they would be written in hand and this multi-path svg scroll technique will be used..just without the scroll
The result went very creative and professional. I am a free software adept, Gimp SVG conversion is messed, what are the great recommendations for download?
Just so we're clear, you can't create this type of animation in Figma. You can only complete the initial part of this tutorial in Figma (creating the svg shapes)
More SVG content to come! I love this stuff.
Please do svg text smear and stretch having some bezeir
Yesss please continue on the svg path :)
Appreciation for the vanilla stuff.
To add:
If the scrollPercentage == 1, transition in a fillOpacity (from 0, set in the CSS, to 1, set in the JS) so it fills in at the end.
To stop the initial transition when the page loads, you can add a .preload * { transition: none !important;} and a preload class to the body and remove that class on the window load.
ah yes, !important my old nemesis
Love how simple the code behind this is!
this is a very smart hack of the stroke dash property of svg. i loved it
Brilliant idea. Thanx.
In browsers with "elastic scroll" ability, the scroll percentage may go out of range, like below zero and above 1. And it causes flickering when you reach the maximum scroll point. So after calculation the scrollPercentage value it should be trimmed like that:
if (scrollPercentage1.0) scrollPercentage=1.0;
Tell me if I'm wrong but JS parses 0.0 as 0, and 1.0 as 1 because the right side is equal to 0. So there is no need to add .0 to any integer.
@@gknt7234 You right. My style is dictated by other scripting languages where there is some difference between integer and float types. It guarantees correct parsing in any case.
For not doing any web development myself I found this very instructive and well explained.
Please do negative space really waiting for it Love from India 🇮🇳 ❤️
I'll be doing it this week.
@@DesignCourse Thanks 😊
this is pretty cool. i think i can't wait for the watch.
SVG is such an underrated tool
You are very good at teaching, and thank you for zooming in.
❤incredibly smart. Thanks 👍
Hi sir
this a very insteresting video and you are a great teacher
thanks
Great tutorial. I tend to use Vivus and also Vivus instant for general animated svgs but this is great especially as its used with vanilla JS, css and scroll percentages. Great job.
I love messing around with the SVG's to do some creative designs with. I have an extension that I use with VS Code called Svg Preview. When you have a svg file in VS Code the screen will split and show you the image. The image will update in real-time when making changes.
👍
It is so much fun to do stuff like this.
Learned something new, thanks!
Small nitpick btw, if you removed the style definition inside the SVG, might as well as remove the *cls-1* class of the ** :D
WOW... thanks, this is super cool!
very elegant and simple 👍
(If I had approached the same problem i would have done it way to complicated)
NGL, Cool & Easy!
Thx for the lesson sir.
this really helps me because I was thinking of making this sort of handwriting letter reveal and I cant just do a simple reveal from left to right...I have to make sure the letters are written like they would be written in hand and this multi-path svg scroll technique will be used..just without the scroll
The result went very creative and professional.
I am a free software adept, Gimp SVG conversion is messed, what are the great recommendations for download?
You, Sir.. are AMAZING!!! Thanks for using vanilla JS. :D
awesome dude!
that was really cool!
Nice one Gaz. I've created something similar for my own website. Looks super cool.
Im typing this at the video intro, im curious to see if you can prevent repaints without something like greensocks, cuz that's what you use it for.
Thank you for the great content as always.
Very good content!! 😊
just a suggestion can make a video about svgomg video tutorial for beginner?
What tool he used to zoom & highlight in like that at around 1:53?
Great video btw!
Please Gary can you tell me your theme settings?
nice video
👍
Why my console didn't show the length of the paths??
what about if I have one path on my svg ?
Hey man, Great tutorial as always. If we animate the svg in after effects and upload it as bg video, would that get us the same result ?
No
You are featured on @Fireship 🤯
I was wondering if you could share the whole formula to get the scroll percentage, because it got cut on frame, great video nonetheless!
let scrollPercentage = (document.documentElement.scrollTop + document.body.scrollTop) / (document.documentElement.scrollHeight - document.documentElement.clientHeight);
coding is hard .-. good thing people still hire front front front end designers. haha
What about Figma? Is it possible to create this design by Figma?
Yes, the SVG elements.
@@DesignCourse It would be great to see a tutorial video of this
@@Franbua it's not needed. Just use the pen tool in Figma to do the same thing I did in illustrator
Just so we're clear, you can't create this type of animation in Figma. You can only complete the initial part of this tutorial in Figma (creating the svg shapes)
@@DesignCourse That's actually what I was trying to find out. Thank you so much :)
Hello, when i launch the page, drawing is complete before i scroll, i search something to change this :(
Thanks for all :)
I've found the solution by myself, opacity:0 in CSS, and this small line of javascript: path.style.opacity = 1;
I wish people would spend less time on making scrolling look good and more time on getting rid of scrolling.
When I saw the thumbnail of this video, I thought it was a girl on it. You could start wearing makeup too. LOL
Love this but hard to not think how much easier this would be done in Webflow... You can do it in under a minute
U looks brad pitt
Dude, time for a haircut :)
absolutely........ not!
Haha. Had to try :)
Don't use this unless you want to drain mobile device batteries
man. vanilla JS is not what you think :) stop using this words)