Cuberto / mouse-follower

A powerful javascript library to create amazing and smooth effects for the mouse cursor on your website.
MIT License
724 stars 60 forks source link

data-magnetic #17

Open HasanSibakhi opened 1 year ago

HasanSibakhi commented 1 year ago

Hi again, I added this tag (data-magnetic), but it didn't work. I think it's disabled!

Thank you.

sagarkhadka commented 1 year ago

For data-magnetic you have to wrap your element with an div that holds data-cursor-stick. Heres an exaple:

<div data-cursor-stick='#stick-here'>
 <div id='stick-here'>
  <BiMenu />
</div>
</div>
HasanSibakhi commented 1 year ago

@sagarkhadka thank you for your time.

Yes, I know this point. I meant the magnet like the picture below https://s3.gifyu.com/images/magnetic.gif

sagarkhadka commented 1 year ago

@HasanSibakhi For the effect I think cuberto has given different repo. You can find it here. Maybe this will help.