What the ROK should invest in to compliment the Japanese military buildup is to invest their Army capabilities, short-range missile defense, and counter artillery/rocket systems to off set North Korea. Let the Japanese build expensive aircraft carriers, long range missile defense, and aircraft to counter China, but what we will likely see is Korea continue to build expensive ships and aircraft to keep up with the Jones in the region:

The Japanese government’s approval of a massive rearmament program to counter China and North Korea’s threats poses a new task for South Korean President Yoon Suk-yeol to look into ways to take advantage of Tokyo’s military buildup to serve Seoul’s security interests, according to experts.
Korea Times
“The recent updates of Japan’s national security strategy now demand South Korea to explore how it will use Japan’s military buildup to contribute to the South Korea-U.S.-Japan trilateral security cooperation to counter North Korea’s nuclear ambitions,” said Jin Chang-soo, the director of Sejong Institute’s Center for Japanese Studies.
“As we use lines of credit for contingencies, national security also requires protection tools for contingencies. … Since South Korea needs the trilateral security cooperation to counter the North’s threat, there will not likely be a major change in the Yoon government’s dovish Japan policy. Rather, the focus should be on how Seoul can take advantage of Japan’s defense cost hike as an opportunity to improve its national security and how it can monitor Japan’s military expansion transparently.”
The advice came after Japan, Friday, unveiled three updated documents on its national security strategies and proclaimed a military buildup, which is seen as the biggest one since World War II and a major breakaway from its defense-only principle.
You can read more at the link.