I was recently asked what kind of clothes do people wear in Indonesia and what kind of clothes should a visitor to Indonesia wear. Both of these are great questions and the answer depends a little on where in Indonesia you are visiting or where you are going.
I suggest wearing casual, appropriate, cool and covering clothing. Dressing in layers is good because it is very hot here, but occasionally you will go into a building with AC to the MAX and get cold, OR, if you travel by motorbike, the wind can be extremely cool and the sun could burn you if riding on the bike for long periods of time. You don't feel the sun at that moment due to the wind. It is very common to see people wearing hats, jackets, socks and gloves while riding on their motorbikes and when they reach their desired destination, they take all the layers off.
You want to look appropriate and acceptable...not rude. The style here is western style just like back home, though many people still wear the traditional batik attire, especially for holidays, work and special celebrations, such as weddings. Women often wear sarongs with a regular shirt or tank top.
Attire here is pretty casual, except for business work, of course. Bali, where I live, is very open and "forgiving". :) You see people here wear anything and everything. As you may figure, Bali is geared towards the tourist so they are more open and not so strict on the rules.
Any questions? :)
On a side note, if anyone is interested in buying batik from Indonesia, let me know! Thanks!