package.json 3.8 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164
  1. {
  2. "name": "puppeteer-core",
  3. "version": "19.0.0",
  4. "description": "A high-level API to control headless Chrome over the DevTools Protocol",
  5. "keywords": [
  6. "puppeteer",
  7. "chrome",
  8. "headless",
  9. "automation"
  10. ],
  11. "type": "commonjs",
  12. "main": "./lib/cjs/puppeteer/puppeteer-core.js",
  13. "types": "./lib/types.d.ts",
  14. "exports": {
  15. ".": {
  16. "types": "./lib/types.d.ts",
  17. "import": "./lib/esm/puppeteer/puppeteer-core.js",
  18. "require": "./lib/cjs/puppeteer/puppeteer-core.js"
  19. },
  20. "./internal/*": {
  21. "import": "./lib/esm/puppeteer/*",
  22. "require": "./lib/cjs/puppeteer/*"
  23. },
  24. "./*": {
  25. "import": "./*",
  26. "require": "./*"
  27. }
  28. },
  29. "repository": {
  30. "type": "git",
  31. "url": "https://github.com/puppeteer/puppeteer/tree/main/packages/puppeteer-core"
  32. },
  33. "engines": {
  34. "node": ">=14.1.0"
  35. },
  36. "scripts": {
  37. "build:third_party": "wireit",
  38. "build:tsc": "wireit",
  39. "build:types": "wireit",
  40. "build": "wireit",
  41. "check": "tsx tools/ensure-correct-devtools-protocol-package",
  42. "clean": "tsc -b --clean && rimraf lib src/generated",
  43. "format:types": "wireit",
  44. "generate:package-json": "wireit",
  45. "generate:sources": "wireit",
  46. "prepack": "wireit"
  47. },
  48. "wireit": {
  49. "prepack": {
  50. "command": "cp ../../README.md README.md",
  51. "files": [
  52. "../../README.md"
  53. ],
  54. "output": [
  55. "README.md"
  56. ]
  57. },
  58. "build": {
  59. "dependencies": [
  60. "build:third_party",
  61. "format:types",
  62. "generate:package-json"
  63. ]
  64. },
  65. "generate:sources": {
  66. "command": "tsx tools/generate_sources.ts",
  67. "files": [
  68. "tools/generate_sources.ts",
  69. "src/templates/**"
  70. ],
  71. "output": [
  72. "src/generated/**",
  73. "src/types.ts"
  74. ]
  75. },
  76. "build:third_party": {
  77. "command": "rollup --config rollup.third_party.config.js",
  78. "dependencies": [
  79. "build:tsc"
  80. ],
  81. "clean": false,
  82. "files": [
  83. "lib/esm/third_party/**",
  84. "lib/cjs/third_party/**"
  85. ],
  86. "output": [
  87. "lib/esm/third_party/**",
  88. "lib/cjs/third_party/**"
  89. ]
  90. },
  91. "generate:package-json": {
  92. "command": "echo '{\"type\": \"module\"}' > lib/esm/package.json",
  93. "clean": "if-file-deleted",
  94. "dependencies": [
  95. "build:tsc"
  96. ],
  97. "output": [
  98. "lib/esm/package.json"
  99. ]
  100. },
  101. "build:types": {
  102. "command": "api-extractor run --local",
  103. "dependencies": [
  104. "build:tsc"
  105. ],
  106. "files": [
  107. "tsconfig.json",
  108. "api-extractor.json",
  109. "lib/esm/puppeteer/types.d.ts"
  110. ],
  111. "output": [
  112. "lib/types.d.ts"
  113. ]
  114. },
  115. "format:types": {
  116. "command": "eslint --cache-location .eslintcache --cache --ext=ts --no-ignore --no-eslintrc -c=../../.eslintrc.types.cjs --fix lib/types.d.ts",
  117. "dependencies": [
  118. "build:types"
  119. ],
  120. "clean": false,
  121. "files": [
  122. "lib/types.d.ts",
  123. "../../.eslintrc.types.cjs"
  124. ],
  125. "output": [
  126. "lib/types.d.ts"
  127. ]
  128. },
  129. "build:tsc": {
  130. "command": "tsc -b",
  131. "clean": "if-file-deleted",
  132. "dependencies": [
  133. "generate:sources"
  134. ],
  135. "files": [
  136. "src/**",
  137. "compat/**",
  138. "**/tsconfig.*.json"
  139. ],
  140. "output": [
  141. "lib/esm/**",
  142. "lib/cjs/**"
  143. ]
  144. }
  145. },
  146. "files": [
  147. "lib",
  148. "!*.tsbuildinfo"
  149. ],
  150. "author": "The Chromium Authors",
  151. "license": "Apache-2.0",
  152. "dependencies": {
  153. "cross-fetch": "3.1.5",
  154. "debug": "4.3.4",
  155. "devtools-protocol": "0.0.1045489",
  156. "extract-zip": "2.0.1",
  157. "https-proxy-agent": "5.0.1",
  158. "proxy-from-env": "1.1.0",
  159. "rimraf": "3.0.2",
  160. "tar-fs": "2.1.1",
  161. "unbzip2-stream": "1.4.3",
  162. "ws": "8.9.0"
  163. }
  164. }