President Reagan, saying "the whole country will be watching" the New Jersey elections next month as a test of party realignment, campaigned here today as part of the GOP's nationwide drive to gain legislative seats and to increase party leverage over redistricting in 1990.

Reagan, accompanied by Gov. Thomas H. Kean (R), helped raise an estimated $200,000 for the state Republican Party, which expects to pour as much as $1 million into 10 tight State Assembly contests.

"The Republican Party of New Jersey is within five seats of control of the State Assembly," Reagan told an estimated 800 donors of $250 each, "and you are going to return the GOP to the dominance that it deserves."

Kean introduced the president by telling the crowd he had followed Reagan's tax-cutting philosophy. "Today, New Jersey is in the forefront of a major electoral change in the country," Kean said.

"You know what I've found, Mr. President, is that your formula works."

Reagan carried New Jersey by more than 600,000 votes last year, beating Democrat Walter F. Mondale by a margin of 1.93 million to 1.26 million.

This year, the governorship and the assembly are up for election, and Kean, according to all polls, appears likely to beat Democratic challenger Peter Shapiro, the Essex County executive, by a wide margin.

Democrats control the assembly with 44 seats, while the Republicans have 36.

A recent poll by Newark's Star-Ledger newspaper, however, found that the public supports electing a Republican State Assembly by a slim 39 percent to 35 percent. That contrasts with an 11-point margin favoring the Democrats two years ago, according to a similar poll.

Nationwide, the Democrats control 66 legislative chambers while the Republicans control 32. Both the GOP and the Democratic Party view the fight for control of the state houses as critical, because the legislatures will determine congressional redistricting after the 1990 census.

In an effort to counter national Republican support of state candidates, the Democratic Party plans to announce soon a program called Project 500, with a goal of raising $5 million and of electing 500 new Democratic members of state legislatures. The Republican Party is expected to spend considerably more than $5 million between now and 1990.

Reagan, in his attempt to build support for State Assembly candidates here, promoted the GOP as the party that "has finally put an end to the tax and enslavement of the middle class in America . . . . The GOP, is, in my view, the party of the American family . . . the Republican Party sees the challenges of the world with clear eyes."

In New Jersey, the Republican Party and the Kean administration, appear to be beneficiaries of the economic recovery, although growing support in public opinion polls has yet to translate into significant Republican gains in the State Assembly. Over the past three elections, the Democrats' margin has remained almost the same, changing by only one vote.

Those attending the fund-raiser at the Hilton argued that the GOP is steadily building a stronger base. Noting the large turnout at the luncheon, Jack Hendrickson, the assembly's assistant minority leader, said that in the past one could "shoot a cannon into a Republican fund-raiser and not hit anyone." CAPTION: Picture, New Jersey Gov. Thomas H. Kean and President Reagan preside at $200,000 fund-raiser in Parsippany. By Frank Johnston-The Washington Post