diff --git a/README.md b/README.md index fd6c1fc..55bf638 100644 --- a/README.md +++ b/README.md @@ -61,6 +61,17 @@ new Vue({ ``` +## I want to copy texts without a specific button! + +Yes, you can do it by using our new method: `this.$copyText`. see [sample2](sample2.html). + +Modern browser have some limiation like that you can't use `window.open` without a user iteraction. +So there's a same restriction on copy things! Test it before you use it. Make sure you are not +using this method inside any async method. + +Use it before reading [this issue](https://github.com/zenorocha/clipboard.js/issues/218) and +[this page](https://github.com/zenorocha/clipboard.js/wiki/Known-Limitations). + ### Contribution PRs welcome, and issues aswell! If you want any feature that we don't have currently, please create a issue for feature request. diff --git a/sample2.html b/sample2.html new file mode 100644 index 0000000..545bfc2 --- /dev/null +++ b/sample2.html @@ -0,0 +1,42 @@ + + +
+ +