gianlucacandiotti / react-router-transitions

Example on how to integrate react-router, react-transition-group and animated
5 stars 2 forks source link

onExit isn't happening #1

Open david-buck opened 7 years ago

david-buck commented 7 years ago

It seems like the exiting route is destroyed before it can be animated out, so handleExit never fired. I have messed around but been unable to get it working.

gianlucacandiotti commented 7 years ago

Yeah a little more work had to be done in order for it to function properly. I'll push some fixes later on today.

gianlucacandiotti commented 7 years ago

@david-buck I already pushed some code that fixes it. Tell me if everything works correctly. I'm not an expert using transitions or react-router so maybe this isn't the best possible way to do it. If you find a better way in the future I'd appreciate some feedback or a pr!