package.json 3.3 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130
  1. {
  2. "name": "eventsource",
  3. "version": "3.0.7",
  4. "description": "WhatWG/W3C compliant EventSource client for Node.js and browsers",
  5. "sideEffects": false,
  6. "type": "module",
  7. "main": "./dist/index.cjs",
  8. "module": "./dist/index.js",
  9. "types": "./dist/index.d.ts",
  10. "exports": {
  11. ".": {
  12. "deno": "./dist/index.js",
  13. "bun": "./dist/index.js",
  14. "source": "./src/index.ts",
  15. "import": "./dist/index.js",
  16. "require": "./dist/index.cjs",
  17. "default": "./dist/index.js"
  18. },
  19. "./package.json": "./package.json"
  20. },
  21. "scripts": {
  22. "build": "pkg-utils build && pkg-utils --strict",
  23. "build:watch": "pkg-utils watch",
  24. "clean": "rimraf dist coverage",
  25. "lint": "eslint . && tsc --noEmit",
  26. "posttest": "npm run lint",
  27. "prebuild": "npm run clean",
  28. "prepare": "npm run build",
  29. "test": "npm run test:node && npm run test:browser",
  30. "test:browser": "tsx test/browser/client.browser.test.ts",
  31. "test:bun": "bun run test/bun/client.bun.test.ts",
  32. "test:deno": "deno run --allow-net --allow-read --allow-env --unstable-sloppy-imports test/deno/client.deno.test.ts",
  33. "test:node": "tsx test/node/client.node.test.ts"
  34. },
  35. "files": [
  36. "!dist/stats.html",
  37. "dist",
  38. "src"
  39. ],
  40. "repository": {
  41. "type": "git",
  42. "url": "git://git@github.com/EventSource/eventsource.git"
  43. },
  44. "keywords": [
  45. "sse",
  46. "eventsource",
  47. "server-sent-events"
  48. ],
  49. "author": "Espen Hovlandsdal <espen@hovlandsdal.com>",
  50. "contributors": [
  51. "Aslak Hellesøy <aslak.hellesoy@gmail.com>",
  52. "Einar Otto Stangvik <einaro.s@gmail.com>"
  53. ],
  54. "license": "MIT",
  55. "engines": {
  56. "node": ">=18.0.0"
  57. },
  58. "browserslist": [
  59. "node >= 18",
  60. "chrome >= 71",
  61. "safari >= 14.1",
  62. "firefox >= 105",
  63. "edge >= 79"
  64. ],
  65. "dependencies": {
  66. "eventsource-parser": "^3.0.1"
  67. },
  68. "devDependencies": {
  69. "@sanity/pkg-utils": "^7.1.0",
  70. "@sanity/semantic-release-preset": "^5.0.0",
  71. "@tsconfig/strictest": "^2.0.5",
  72. "@types/sinon": "^17.0.3",
  73. "@typescript-eslint/eslint-plugin": "^6.11.0",
  74. "@typescript-eslint/parser": "^6.11.0",
  75. "esbuild": "^0.25.1",
  76. "eslint": "^8.57.0",
  77. "eslint-config-prettier": "^9.1.0",
  78. "eslint-config-sanity": "^7.1.3",
  79. "eventsource-encoder": "^1.0.0",
  80. "playwright": "^1.48.2",
  81. "prettier": "^3.5.3",
  82. "rimraf": "^5.0.5",
  83. "rollup-plugin-visualizer": "^5.12.0",
  84. "semantic-release": "^24.2.0",
  85. "sinon": "^17.0.1",
  86. "tsx": "^4.19.2",
  87. "typescript": "^5.8.2",
  88. "undici": "^6.20.1"
  89. },
  90. "overrides": {
  91. "cross-spawn": "7.0.6"
  92. },
  93. "bugs": {
  94. "url": "https://github.com/EventSource/eventsource/issues"
  95. },
  96. "homepage": "https://github.com/EventSource/eventsource#readme",
  97. "prettier": {
  98. "semi": false,
  99. "printWidth": 100,
  100. "bracketSpacing": false,
  101. "singleQuote": true
  102. },
  103. "eslintConfig": {
  104. "parserOptions": {
  105. "ecmaVersion": 9,
  106. "sourceType": "module",
  107. "ecmaFeatures": {
  108. "modules": true
  109. }
  110. },
  111. "extends": [
  112. "sanity",
  113. "sanity/typescript",
  114. "prettier"
  115. ],
  116. "ignorePatterns": [
  117. "lib/**/"
  118. ],
  119. "globals": {
  120. "globalThis": false
  121. },
  122. "rules": {
  123. "no-undef": "off",
  124. "no-empty": "off"
  125. }
  126. },
  127. "publishConfig": {
  128. "provenance": true
  129. }
  130. }