dom works when canvas not