There are quite a few reasons why you should not put your computer near a window.
Desk location can produce a sharp contrast between the light in front of you and the brightness level of the computer.
When you have this situation your eyes have to work much harder to adapt each time you look up.
This is going to cause eye strain.
So say goodbye to that lovely view outside your window.

To keep your eyes from feeling tired and sore (which is called Computer Vision Syndrome) after a long stint of typing, don’t forget the 20/20/20 rule.
Look away from your computer and take a vision break every 20 or so minutes.
Keep your eyes off the screen for 20 seconds and focus on an object that is at least 20 feet away – about 6 metres.
When you are sitting at your desk, make sure that you do not have overhead lights or a lamp placed directly behind you.
These will contrast too sharply with the light on your monitor.
Move the monitor to a different angle or change the lighting, if possible.