checking for defined View is standard js