This is the idea Cherico! But this way, as Aphrodite said, you may have trouble with objects and especially with enemies / NPCs who decide to walk to the edge of the world. They will not be visible or not will attack depending on which side you are.
Searching in programming forums, I saw that programmers make the layout work as a tiled world, fully functional. But seems that is something very complex even for programmers.
But thank you for the example! Depending on the game, it can work perfectly.