Hi @thierrymichel,
As discussed this morning, here is a fresh bug found in @barba/core. It seems that the appear transition hook is called on every browser reload, even if there is a custom from/to rule that target a specific namespace/route.
import barba from '@barba/core';
barba.init({
transitions: [{
name: 'fade',
enter: fadeIn,
leave: fadeOut
}, {
name: 'slider-leave',
from: {
namespace: ['index']
},
enter: slideIn,
leave: slideOut
}, {
name: 'slider-enter',
to: {
namespace: ['index']
},
appear: slideIn, // this hook is fired on every browser reload, even on other namespace
enter: slideIn,
leave: slideOut
}]
});
Here is the debug console log when the transition is fired:
[@barba/core] Transition found [appear]
{name: "slider-enter", to: {鈥, appear: 茠, enter: 茠, leave: 茠}
I am using the latest @barba/[email protected] :v:
Most helpful comment
Closed by https://github.com/barbajs/barba/commit/20cafe1c74cf2321cd4da12ccfd2cef3c53bcfc7