Skip to content

Commit

Permalink
Update README.md
Browse files Browse the repository at this point in the history
  • Loading branch information
nuxodin committed Mar 2, 2023
1 parent aa703a5 commit b5292a1
Showing 1 changed file with 1 addition and 3 deletions.
4 changes: 1 addition & 3 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -35,9 +35,7 @@ import {dialog} from "https://cdn.jsdelivr.net/gh/u1ui/dialog.js@x.x.x/dialog.mi
To get sure your lib works even if the script does not load, you can fallback to the native confirm/alert/prompt function.

```js
const {confirm} = await import('../fails/dialog.js').catch(e=>{
return {confirm: window.confirm};
});
const {confirm} = await import('../fails/dialog.js').catch(e=>window);
await confirm('test');
```

Expand Down

0 comments on commit b5292a1

Please sign in to comment.