Travis build: 391
This commit is contained in:
@ -7,9 +7,9 @@ Pass a second argument to simulate a link click (`true` - default) or an HTTP re
|
||||
|
||||
```js
|
||||
const redirect = (url, asLink = true) =>
|
||||
asLink ? window.location.href = url : window.location.replace(url);
|
||||
asLink ? (window.location.href = url) : window.location.replace(url);
|
||||
```
|
||||
|
||||
```js
|
||||
redirect('https://google.com')
|
||||
redirect('https://google.com');
|
||||
```
|
||||
|
||||
Reference in New Issue
Block a user