load 2 lua with 1 variable, Composer

Hi, is that posible to load 2 lua with 1 variable (to substitude each other) in difrent lua with composer ?

for ex :

page1.lua —> require page1setting.lua —> variable page=1

page2.lua —> requite page2setting.lua —> variable page=2

i have done that, but when im back to page1, variable page still in page=2.

any suggestion ?