diff options
Diffstat (limited to 'src/lib/utils.js')
| -rw-r--r-- | src/lib/utils.js | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/src/lib/utils.js b/src/lib/utils.js index 22c88522..7831c519 100644 --- a/src/lib/utils.js +++ b/src/lib/utils.js @@ -17,3 +17,7 @@ export const post = (url, body) => body: JSON.stringify(body), headers: { accept: 'application/json', 'content-type': 'application/json' } }).then((r) => r.json()); + +export const copy = (text) => { + navigator.clipboard.writeText(text); +}; |
