package.json 3.8 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126
  1. {
  2. "name": "css-tree",
  3. "version": "3.2.1",
  4. "description": "A tool set for CSS: fast detailed parser (CSS → AST), walker (AST traversal), generator (AST → CSS) and lexer (validation and matching) based on specs and browser implementations",
  5. "author": "Roman Dvornov <rdvornov@gmail.com> (https://github.com/lahmatiy)",
  6. "license": "MIT",
  7. "repository": "csstree/csstree",
  8. "keywords": [
  9. "css",
  10. "ast",
  11. "tokenizer",
  12. "parser",
  13. "walker",
  14. "lexer",
  15. "generator",
  16. "utils",
  17. "syntax",
  18. "validation"
  19. ],
  20. "type": "module",
  21. "module": "./lib/index.js",
  22. "sideEffects": false,
  23. "main": "./cjs/index.cjs",
  24. "exports": {
  25. ".": {
  26. "import": "./lib/index.js",
  27. "require": "./cjs/index.cjs"
  28. },
  29. "./dist/*": "./dist/*.js",
  30. "./package.json": "./package.json",
  31. "./tokenizer": {
  32. "import": "./lib/tokenizer/index.js",
  33. "require": "./cjs/tokenizer/index.cjs"
  34. },
  35. "./parser": {
  36. "import": "./lib/parser/index.js",
  37. "require": "./cjs/parser/index.cjs"
  38. },
  39. "./selector-parser": {
  40. "import": "./lib/parser/parse-selector.js",
  41. "require": "./cjs/parser/parse-selector.cjs"
  42. },
  43. "./generator": {
  44. "import": "./lib/generator/index.js",
  45. "require": "./cjs/generator/index.cjs"
  46. },
  47. "./walker": {
  48. "import": "./lib/walker/index.js",
  49. "require": "./cjs/walker/index.cjs"
  50. },
  51. "./convertor": {
  52. "import": "./lib/convertor/index.js",
  53. "require": "./cjs/convertor/index.cjs"
  54. },
  55. "./lexer": {
  56. "import": "./lib/lexer/index.js",
  57. "require": "./cjs/lexer/index.cjs"
  58. },
  59. "./definition-syntax": {
  60. "import": "./lib/definition-syntax/index.js",
  61. "require": "./cjs/definition-syntax/index.cjs"
  62. },
  63. "./definition-syntax-data": {
  64. "import": "./lib/data.js",
  65. "require": "./cjs/data.cjs"
  66. },
  67. "./definition-syntax-data-patch": {
  68. "import": "./lib/data-patch.js",
  69. "require": "./cjs/data-patch.cjs"
  70. },
  71. "./utils": {
  72. "import": "./lib/utils/index.js",
  73. "require": "./cjs/utils/index.cjs"
  74. }
  75. },
  76. "browser": {
  77. "./cjs/data.cjs": "./dist/data.cjs",
  78. "./cjs/version.cjs": "./dist/version.cjs",
  79. "./lib/data.js": "./dist/data.js",
  80. "./lib/version.js": "./dist/version.js"
  81. },
  82. "unpkg": "dist/csstree.esm.js",
  83. "jsdelivr": "dist/csstree.esm.js",
  84. "scripts": {
  85. "watch": "npm run build -- --watch",
  86. "build": "npm run bundle && npm run esm-to-cjs --",
  87. "build-and-test": "npm run build && npm run test:dist && npm run test:cjs",
  88. "bundle": "node scripts/bundle",
  89. "bundle-and-test": "npm run bundle && npm run test:dist",
  90. "esm-to-cjs": "node scripts/esm-to-cjs.cjs",
  91. "esm-to-cjs-and-test": "npm run esm-to-cjs && npm run test:cjs",
  92. "lint": "eslint lib scripts && node scripts/review-syntax-patch --lint && node scripts/update-docs --lint",
  93. "lint-and-test": "npm run lint && npm test",
  94. "update:docs": "node scripts/update-docs",
  95. "review:syntax-patch": "node scripts/review-syntax-patch",
  96. "test": "mocha lib/__tests --require lib/__tests/helpers/setup.js --reporter progress",
  97. "test:cjs": "mocha cjs/__tests --require lib/__tests/helpers/setup.js --reporter progress",
  98. "test:dist": "mocha dist/__tests --reporter progress",
  99. "coverage": "c8 --exclude lib/__tests --reporter=lcovonly npm test",
  100. "prepublishOnly": "npm run lint-and-test && npm run build-and-test"
  101. },
  102. "dependencies": {
  103. "mdn-data": "2.27.1",
  104. "source-map-js": "^1.2.1"
  105. },
  106. "devDependencies": {
  107. "c8": "^11.0.0",
  108. "clap": "^2.0.1",
  109. "esbuild": "^0.27.3",
  110. "eslint": "^8.50.0",
  111. "json-to-ast": "^2.1.0",
  112. "mocha": "^9.2.2",
  113. "rollup": "^2.80.0"
  114. },
  115. "engines": {
  116. "node": "^10 || ^12.20.0 || ^14.13.0 || >=15.0.0"
  117. },
  118. "files": [
  119. "data",
  120. "dist",
  121. "cjs",
  122. "!cjs/__tests",
  123. "lib",
  124. "!lib/__tests"
  125. ]
  126. }