There are no guaranteed ways to prevent dooring. The best one can hope for is to reduce the odds. My first and last time doored was in 1966, and I escaped uninjured, though both the bike and car were damaged.
With decades of urban riding experience, the best I can off is vigilance and situational awareness. For example, one thing I do is watch down the road for anyone parking. That's a car I mentally tag as having a driver to open his door anytime soon, and stay prepared to deal with it.
Also, since I live and ride in NYC and close in suburbs, I make it a point to ride to the left side of one way streets. The logic is simple, all cars have drivers, but only a small minority have passengers, so fewer will be opening they're passenger side doors.
BTW- despite my age, I still have the reflexes of a cat, something I credit to urban riding in the NYC metro area.
__________________
FB
Chain-L site
An ounce of diagnosis is worth a pound of cure.
Just because I'm tired of arguing, doesn't mean you're right.
“One accurate measurement is worth a thousand expert opinions” - Adm Grace Murray Hopper - USN
WARNING, I'm from New York. Thin skinned people should maintain safe distance.