SPOILERS (for something that happened nearly 10 years ago…)
In the third-to-last episode of the second-to-last season, Darlene (pregnant) and David get married and Dan suffers a heart attack. The next episode is the family dealing with what happened, while in the final episode of the season, Dan can’t deal with his new restricted diet and exercise plan, Dan and Roseanne have a huge fight (one of those “real” moments you were talking about…) and Roseanne walks out.
In the first episode of the final season, Roseanne is at Jackie’s and gets lost in TV shows, appearing as the female lead character in I Dream of Jeannie, That Girl and the Mary Tyler Moore Show. At the end of that episode, Jackie is watching TV and realizes they’ve won the lottery.
Then it all goes downhill.
The family goes on Jerry Springer,
Dan leaves to take his mentally-ill mother to a hospital in California, while Roseanne and Jackie go to an upscale spa,
a “Moldavian Prince” (played by Jim Varney, of all people) sees Jackie on TV and falls in love,
Roseanne and Jackie go to a high-class New York halloween party with the Absolutely Fabulous women,
everybody but Dan visits some snobby family on Martha’s Vinyard,
everybody but Dan goes on a train ride to Washington D.C. but it gets taken over by terrorists and Roseanne saves the day,
at Thanksgiving, Bev (Roseanne’s mom) reveals that she’s gay,
Bev visits her mom, who says she doesn’t know who Bev’s father is (the most normal episode of the bunch, IMO),
Dan comes back for Christmas (another semi-normal episode),
Jackie finds out Dan fell in love with another woman in California and makes him tell Roseanne,
Dan leaves and Roseanne drives around Lanford binging on fast food,
Roseanne holes up in her room while the family tries to coax her out,
Roseanne and Jackie go to the Lanford Country Club and become friends with Edgar Wellman, Jr., the son of the guy who owned the plastics plant where the two worked at the beginning of the series (normalish),
Roseanne and Wellman develop a little thing for each other,
Dan and Roseanne try to reconciliate and Darlene (pregnant) is taken to the hospital,
Darlene has her baby like four months early and it almost dies,
then two normal episodes where a bunch of random non-important stuff happens,
Dan’s mom is released from the hospital and Dan thinks she might come to Lanford to kill him,
finally, in the last (two-part) episode, Darlene and David’s baby comes home from the hospital, Becky and Mark reveal Becky’s pregnant, Leon and Scott announce they’re adopting a baby, and Roseanne reveals that the whole series was her own writing based upon her character’s life.
So…Roseanne, the comic, created a TV character who created a TV series, which is what we saw.