web_screencapture
TypeScript icon, indicating that this package has built-in type declarations

1.0.2 • Public • Published

screenCapture

网页截图

install

安装很简单,可以用npm 或者浏览器引入screenCapture.js

npm i web_screencapture
// 或者
npm install web_screencapture -i

use

 
import ScreenCapture from 'web_screencapture';

let sc = new ScreenCapture({
    copyType: 'all'
});
sc.init();

键盘按下ctrl+b开始截图;ctrl+m全屏截图;esc退出截图

options

初始化构建函数的参数如下:

  • copyType: 截图后的行为:all : 弹出弹窗选择;download: 直接下载截图;_blank: 新窗口打开截图
  • keyCode: 键盘触发截图的keyCode,默认66(b)
  • fkeyCode: 键盘触发全屏截图的keyCode,默认77(m)

screen capture

开始截图

截图完成

Readme

Keywords

Package Sidebar

Install

npm i web_screencapture

Weekly Downloads

1

Version

1.0.2

License

MIT

Unpacked Size

191 kB

Total Files

5

Last publish

Collaborators

  • hero_666