package.json 2.5 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182838485868788
  1. {
  2. "name": "tiny-invariant",
  3. "version": "1.3.1",
  4. "description": "A tiny invariant function",
  5. "author": "Alex Reardon <alexreardon@gmail.com>",
  6. "license": "MIT",
  7. "keywords": [
  8. "invariant",
  9. "error",
  10. "assert",
  11. "asserts"
  12. ],
  13. "repository": {
  14. "type": "git",
  15. "url": "https://github.com/alexreardon/tiny-invariant.git"
  16. },
  17. "bugs": {
  18. "url": "https://github.com/alexreardon/tiny-invariant/issues"
  19. },
  20. "main": "dist/tiny-invariant.cjs.js",
  21. "module": "dist/tiny-invariant.esm.js",
  22. "types": "dist/tiny-invariant.d.ts",
  23. "exports": {
  24. ".": {
  25. "import": "./dist/esm/tiny-invariant.js",
  26. "default": {
  27. "types": "./dist/tiny-invariant.d.ts",
  28. "default": "./dist/tiny-invariant.cjs.js"
  29. }
  30. }
  31. },
  32. "sideEffects": false,
  33. "files": [
  34. "/dist",
  35. "/src"
  36. ],
  37. "size-limit": [
  38. {
  39. "path": "dist/tiny-invariant.min.js",
  40. "limit": "217B"
  41. },
  42. {
  43. "path": "dist/tiny-invariant.js",
  44. "limit": "267B"
  45. },
  46. {
  47. "path": "dist/tiny-invariant.cjs.js",
  48. "limit": "171B"
  49. },
  50. {
  51. "path": "dist/tiny-invariant.esm.js",
  52. "import": "foo",
  53. "limit": "112B"
  54. }
  55. ],
  56. "scripts": {
  57. "test": "yarn jest",
  58. "test:size": "yarn build && yarn size-limit",
  59. "prettier:write": "yarn prettier --debug-check src/** test/**",
  60. "prettier:check": "yarn prettier --write src/** test/**",
  61. "typescript:check": "yarn tsc --noEmit src/*.ts test/*.ts",
  62. "validate": "yarn prettier:check && yarn typescript:check",
  63. "build:clean": "rimraf dist",
  64. "build:flow": "cp src/tiny-invariant.js.flow dist/tiny-invariant.cjs.js.flow",
  65. "build:typescript": "tsc ./src/tiny-invariant.ts --emitDeclarationOnly --declaration --outDir ./dist",
  66. "build:typescript:esm": "tsc ./src/tiny-invariant.ts --emitDeclarationOnly --declaration --outDir ./dist/esm",
  67. "build:dist": "yarn rollup --config rollup.config.js",
  68. "build": "yarn build:clean && yarn build:dist && yarn build:typescript && yarn build:typescript:esm",
  69. "prepublishOnly": "yarn build"
  70. },
  71. "devDependencies": {
  72. "@rollup/plugin-replace": "^4.0.0",
  73. "@rollup/plugin-typescript": "^8.5.0",
  74. "@size-limit/preset-small-lib": "^8.1.0",
  75. "@types/jest": "^29.0.3",
  76. "@types/rollup": "^0.54.0",
  77. "expect-type": "^0.14.2",
  78. "jest": "^29.0.3",
  79. "prettier": "^2.7.1",
  80. "rimraf": "^3.0.2",
  81. "rollup": "^2.79.1",
  82. "rollup-plugin-terser": "^7.0.2",
  83. "size-limit": "^8.1.0",
  84. "ts-jest": "^29.0.2",
  85. "tslib": "^2.4.0",
  86. "typescript": "^4.8.4"
  87. }
  88. }