In the annals of bad timing, Indonesia choosing Jan. 14 to broaden the welcome mat for foreign investors deserves prominent mention. President Joko Widodo couldn't have known terrorists would pick the same day for synchronized attacks in Jakarta. But the act would appear to blow his argument Indonesia is a reborn investment destination to smithereens.

Or so the world thought for about 24 hours. In the days since, events surrounding an attack that killed two civilians should bolster the view Indonesia is back and that its newish leader may be the transformational figure voters and investors hoped. There are even some lessons here for the West as Islamic State spreads mayhem around the globe.

Indonesia, let's remember, has come an incredibly long way since the dark days of 1997. Back then, it seemed far more destined for failed statehood than the investment-grade economy it is today. The credit for that spectacular feat goes to former President Susilo Bambang Yudhoyono, who from 2004 to 2014 curbed the role of the military, attacked graft, cut red tape and upped investments in infrastructure and education. He also clamped down on radical Islamic elements responsible for a 2002 Bali attack that killed more than 200.