Demonstrations are nearly over in Turkey. Some demonstrations still happens, but for protesting the police who killed demonstrators. Since police do not interfere to the demonstrators due to previous police brutality events, nearly no clashes happen.
You can also get information from local citizens about the protests since all are previously planned demonstrations now. Since demonstrations take place in Taksim Square, you probably have no trouble while you keep away from Taksim Square while there are planned demonstrations in there.
İstiklal Avenue will probably be one of the places you wish to visit in İstanbul. It is close to Taksim Square, but since it is really crowded, you probably will not have any problem about demonstrations in there. But still, it is a better idea to go there when there is no demonstration in Taksim.
Beside all these, places that demonstrations took place is only a very small part of İstanbul, and not close to places you will visit in İstanbul.
Like İstanbul, there are a few important points for demonstrations in Ankara. By keeping yourself away from these sites while (previously planned) demonstrations took place would be enough.
Keeping these in mind, I guess you will have no problem in your trip to Turkey.