Holy smokes—we were not expecting Eilis to fall so hard for Jim Farrell. Either this girl is boy-crazy beyond belief, or there's something a bit deeper going on here.
To Eilis, Jim represents Ireland. Think back to when she watches him run along the beach with George, thinking to herself that "no American man [...] would move as unself-consciously as these two did" (4.135). We can also see this dynamic at play when Eilis observes her mother's joy at their budding relationship. In both instances, Jim represents the country that Eilis left behind when she moved to Brooklyn—a country that, after Rose's death, suddenly seems much more inviting.
It's for these same reasons, however, that Eilis knows that things won't work with Jim. She's already made choices in her life—moved to a new country and gotten married—and she knows that Jim is on a completely different path. At his core, Jim is "conservative" and "liked his position in the town," a position that would be inevitably damaged if it was revealed that he got hot n' heavy with a married lady (4.264).
With that, Eilis returns to Brooklyn. We don't know what will come next for her (she even alludes to writing a letter to Jim that will explain the situation) but we know that she's finally made her choice: she's a BKLYN girl through and through.