An open API service indexing awesome lists of open source software.

https://github.com/gwendall/meteor-iron-router-cordova-only

Redirects visitors that are not accessing your app through Cordova
https://github.com/gwendall/meteor-iron-router-cordova-only

Last synced: 2 months ago
JSON representation

Redirects visitors that are not accessing your app through Cordova

Awesome Lists containing this project

README

        

Installation
------------

``` sh
meteor add gwendall:iron-router-cordova-only
```

What is does
============

This package redirects visitors that are not accessing your app through Cordova.
It is particularly handy if you don't want to let people access your app via a web browser by visiting its mobile-server url.

Configuration
=======

``` javascript
Router.cordova.only({
redirectTo: 'https://www.youtube.com/watch?v=dQw4w9WgXcQ', // URL the visitor will be redirected to
redirectingTpl: 'redirecting', // Provide a template name if you want to temporarily render it before redirecting
redirectingDelay: 1000, // Delay before redirecting
only: [], // Only apply redirect to certain routes - pass an array of route names
except: [], // Apply redirect to all routes except some - pass an array of route names
development: true // Pass true if you want the redirect to happen in development mode (false by default)
});
```