{"_id":"data-urls","_rev":"4194677","name":"data-urls","description":"Parses data: URLs","dist-tags":{"latest":"7.0.0"},"maintainers":[{"name":"domenic","email":""},{"name":"joris-van-der-wel","email":"joris@jorisvanderwel.com"},{"name":"sebmaster","email":""},{"name":"timothygu","email":"timothygu99@gmail.com"},{"name":"tmpvar","email":"tmpvar@gmail.com"},{"name":"zirro","email":"code@zirro.se"}],"time":{"modified":"2026-03-02T02:52:19.000Z","created":"2018-01-31T22:31:54.529Z","7.0.0":"2026-02-02T05:07:21.064Z","6.0.1":"2026-01-20T03:18:12.611Z","6.0.0":"2025-09-13T04:00:51.899Z","5.0.0":"2023-11-11T08:26:58.320Z","4.0.0":"2023-01-03T02:27:49.741Z","3.0.2":"2022-04-25T00:45:15.708Z","3.0.1":"2021-10-06T17:03:00.337Z","3.0.0":"2021-07-19T19:07:45.540Z","2.0.0":"2020-01-02T20:33:59.814Z","1.1.0":"2018-10-26T13:05:29.091Z","1.0.1":"2018-08-18T21:22:26.198Z","1.0.0":"2018-01-31T22:31:54.529Z"},"users":{"nsfmc":true},"author":{"name":"Domenic Denicola","email":"d@domenic.me","url":"https://domenic.me/"},"repository":{"type":"git","url":"git+https://github.com/jsdom/data-urls.git"},"versions":{"7.0.0":{"name":"data-urls","description":"Parses data: URLs","keywords":["data url","data uri","data:","http","fetch","whatwg"],"version":"7.0.0","author":{"name":"Domenic Denicola","email":"d@domenic.me","url":"https://domenic.me/"},"license":"MIT","repository":{"type":"git","url":"git+https://github.com/jsdom/data-urls.git"},"main":"lib/parser.js","scripts":{"test":"node --test","coverage":"c8 node --test --experimental-test-coverage","lint":"eslint","pretest":"node scripts/get-latest-platform-tests.mjs"},"dependencies":{"whatwg-mimetype":"^5.0.0","whatwg-url":"^16.0.0"},"devDependencies":{"@domenic/eslint-config":"^4.1.0","c8":"^10.1.3","eslint":"^9.39.2","globals":"^17.3.0"},"engines":{"node":"^20.19.0 || ^22.12.0 || >=24.0.0"},"c8":{"reporter":["html"],"exclude":["scripts/","test/"]},"gitHead":"45fcb77450c3d0a58f3fe845a76eda8ea954054a","_id":"data-urls@7.0.0","bugs":{"url":"https://github.com/jsdom/data-urls/issues"},"homepage":"https://github.com/jsdom/data-urls#readme","_nodeVersion":"24.13.0","_npmVersion":"11.6.2","dist":{"shasum":"6dce8b63226a1ecfdd907ce18a8ccfb1eee506d3","size":3726,"noattachment":false,"key":"/data-urls/-/data-urls-7.0.0.tgz","tarball":"http://registry.cnpm.dingdandao.com/data-urls/download/data-urls-7.0.0.tgz"},"_npmUser":{"name":"GitHub Actions","email":"npm-oidc-no-reply@github.com","trustedPublisher":{"id":"github","oidcConfigId":"oidc:b1df1ea3-1619-4cf1-ae9d-fa878179e210"}},"directories":{},"maintainers":[{"name":"domenic","email":""},{"name":"joris-van-der-wel","email":"joris@jorisvanderwel.com"},{"name":"sebmaster","email":""},{"name":"timothygu","email":"timothygu99@gmail.com"},{"name":"tmpvar","email":"tmpvar@gmail.com"},{"name":"zirro","email":"code@zirro.se"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages-npm-production","tmp":"tmp/data-urls_7.0.0_1770008840924_0.08811013374189636"},"_hasShrinkwrap":false,"_cnpmcore_publish_time":"2026-02-02T05:07:21.064Z","publish_time":1770008841064,"_source_registry_name":"default","_cnpm_publish_time":1770008841064},"6.0.1":{"name":"data-urls","description":"Parses data: URLs","keywords":["data url","data uri","data:","http","fetch","whatwg"],"version":"6.0.1","author":{"name":"Domenic Denicola","email":"d@domenic.me","url":"https://domenic.me/"},"license":"MIT","repository":{"type":"git","url":"git+https://github.com/jsdom/data-urls.git"},"main":"lib/parser.js","scripts":{"test":"node --test","coverage":"c8 node --test --experimental-test-coverage","lint":"eslint","pretest":"node scripts/get-latest-platform-tests.mjs"},"dependencies":{"whatwg-mimetype":"^5.0.0","whatwg-url":"^15.1.0"},"devDependencies":{"@domenic/eslint-config":"^4.0.1","c8":"^10.1.3","eslint":"^9.39.2","globals":"^17.0.0"},"engines":{"node":">=20"},"c8":{"reporter":["html"],"exclude":["scripts/","test/"]},"gitHead":"99af36f6fb489a397ed0d48e31dd18031233ab83","_id":"data-urls@6.0.1","bugs":{"url":"https://github.com/jsdom/data-urls/issues"},"homepage":"https://github.com/jsdom/data-urls#readme","_nodeVersion":"24.12.0","_npmVersion":"11.6.2","dist":{"shasum":"b448c8637997abe34978c9bfdb3d0a7778540184","size":3706,"noattachment":false,"key":"/data-urls/-/data-urls-6.0.1.tgz","tarball":"http://registry.cnpm.dingdandao.com/data-urls/download/data-urls-6.0.1.tgz"},"_npmUser":{"name":"GitHub Actions","email":"npm-oidc-no-reply@github.com","trustedPublisher":{"id":"github","oidcConfigId":"oidc:b1df1ea3-1619-4cf1-ae9d-fa878179e210"}},"directories":{},"maintainers":[{"name":"domenic","email":""},{"name":"joris-van-der-wel","email":"joris@jorisvanderwel.com"},{"name":"sebmaster","email":""},{"name":"timothygu","email":"timothygu99@gmail.com"},{"name":"tmpvar","email":"tmpvar@gmail.com"},{"name":"zirro","email":"code@zirro.se"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages-npm-production","tmp":"tmp/data-urls_6.0.1_1768879092469_0.697272478341632"},"_hasShrinkwrap":false,"_cnpmcore_publish_time":"2026-01-20T03:18:12.611Z","publish_time":1768879092611,"_source_registry_name":"default","_cnpm_publish_time":1768879092611},"6.0.0":{"name":"data-urls","description":"Parses data: URLs","keywords":["data url","data uri","data:","http","fetch","whatwg"],"version":"6.0.0","author":{"name":"Domenic Denicola","email":"d@domenic.me","url":"https://domenic.me/"},"license":"MIT","repository":{"type":"git","url":"git+https://github.com/jsdom/data-urls.git"},"main":"lib/parser.js","scripts":{"test":"node --test","coverage":"c8 node --test --experimental-test-coverage","lint":"eslint .","pretest":"node scripts/get-latest-platform-tests.js"},"dependencies":{"whatwg-mimetype":"^4.0.0","whatwg-url":"^15.0.0"},"devDependencies":{"@domenic/eslint-config":"^4.0.1","c8":"^10.1.3","eslint":"^9.35.0","globals":"^16.4.0"},"engines":{"node":">=20"},"c8":{"reporter":["text","html"],"exclude":["scripts/","test/"]},"_id":"data-urls@6.0.0","gitHead":"5f50081f015eef0268ac87d090584a5549c40f57","bugs":{"url":"https://github.com/jsdom/data-urls/issues"},"homepage":"https://github.com/jsdom/data-urls#readme","_nodeVersion":"24.4.1","_npmVersion":"11.4.2","dist":{"shasum":"95a7943c8ac14c1d563b771f2621cc50e8ec7744","size":3507,"noattachment":false,"key":"/data-urls/-/data-urls-6.0.0.tgz","tarball":"http://registry.cnpm.dingdandao.com/data-urls/download/data-urls-6.0.0.tgz"},"_npmUser":{"name":"domenic","email":"d@domenic.me"},"directories":{},"maintainers":[{"name":"domenic","email":""},{"name":"joris-van-der-wel","email":"joris@jorisvanderwel.com"},{"name":"sebmaster","email":""},{"name":"timothygu","email":"timothygu99@gmail.com"},{"name":"tmpvar","email":"tmpvar@gmail.com"},{"name":"zirro","email":"code@zirro.se"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages-npm-production","tmp":"tmp/data-urls_6.0.0_1757736051705_0.5013319468820487"},"_hasShrinkwrap":false,"_cnpmcore_publish_time":"2025-09-13T04:00:51.899Z","publish_time":1757736051899,"_source_registry_name":"default","_cnpm_publish_time":1757736051899},"5.0.0":{"name":"data-urls","description":"Parses data: URLs","keywords":["data url","data uri","data:","http","fetch","whatwg"],"version":"5.0.0","author":{"name":"Domenic Denicola","email":"d@domenic.me","url":"https://domenic.me/"},"license":"MIT","repository":{"type":"git","url":"git+https://github.com/jsdom/data-urls.git"},"main":"lib/parser.js","scripts":{"test":"node --test","coverage":"c8 node --test --experimental-test-coverage","lint":"eslint .","pretest":"node scripts/get-latest-platform-tests.js"},"dependencies":{"whatwg-mimetype":"^4.0.0","whatwg-url":"^14.0.0"},"devDependencies":{"@domenic/eslint-config":"^3.0.0","c8":"^8.0.1","eslint":"^8.53.0"},"engines":{"node":">=18"},"c8":{"reporter":["text","html"],"exclude":["scripts/","test/"]},"_id":"data-urls@5.0.0","gitHead":"3ee6d206c41247593507d3870accef2c9e950e60","bugs":{"url":"https://github.com/jsdom/data-urls/issues"},"homepage":"https://github.com/jsdom/data-urls#readme","_nodeVersion":"21.1.0","_npmVersion":"10.2.0","dist":{"shasum":"2f76906bce1824429ffecb6920f45a0b30f00dde","size":3475,"noattachment":false,"key":"/data-urls/-/data-urls-5.0.0.tgz","tarball":"http://registry.cnpm.dingdandao.com/data-urls/download/data-urls-5.0.0.tgz"},"_npmUser":{"name":"domenic","email":"d@domenic.me"},"directories":{},"maintainers":[{"name":"domenic","email":""},{"name":"joris-van-der-wel","email":"joris@jorisvanderwel.com"},{"name":"sebmaster","email":""},{"name":"timothygu","email":"timothygu99@gmail.com"},{"name":"tmpvar","email":"tmpvar@gmail.com"},{"name":"zirro","email":"code@zirro.se"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/data-urls_5.0.0_1699691218155_0.16610002353173003"},"_hasShrinkwrap":false,"_cnpmcore_publish_time":"2023-11-11T08:26:58.320Z","publish_time":1699691218320,"_source_registry_name":"default","_cnpm_publish_time":1699691218320},"4.0.0":{"name":"data-urls","description":"Parses data: URLs","keywords":["data url","data uri","data:","http","fetch","whatwg"],"version":"4.0.0","author":{"name":"Domenic Denicola","email":"d@domenic.me","url":"https://domenic.me/"},"license":"MIT","repository":{"type":"git","url":"git+https://github.com/jsdom/data-urls.git"},"main":"lib/parser.js","scripts":{"test":"jest","coverage":"jest --coverage","lint":"eslint .","pretest":"node scripts/get-latest-platform-tests.js"},"dependencies":{"abab":"^2.0.6","whatwg-mimetype":"^3.0.0","whatwg-url":"^12.0.0"},"devDependencies":{"@domenic/eslint-config":"^3.0.0","eslint":"^8.31.0","jest":"^29.3.1","minipass-fetch":"^3.0.1"},"engines":{"node":">=14"},"jest":{"coverageDirectory":"coverage","coverageReporters":["lcov","text-summary"],"testEnvironment":"node","testMatch":["<rootDir>/test/**/*.js"],"coveragePathIgnorePatterns":["<rootDir>/node_modules/(?!(abab/lib/atob.js))"]},"gitHead":"55b4e54384921231893545e2c592afdb5685a986","bugs":{"url":"https://github.com/jsdom/data-urls/issues"},"homepage":"https://github.com/jsdom/data-urls#readme","_id":"data-urls@4.0.0","_nodeVersion":"19.1.0","_npmVersion":"8.19.3","dist":{"shasum":"333a454eca6f9a5b7b0f1013ff89074c3f522dd4","size":3565,"noattachment":false,"key":"/data-urls/-/data-urls-4.0.0.tgz","tarball":"http://registry.cnpm.dingdandao.com/data-urls/download/data-urls-4.0.0.tgz"},"_npmUser":{"name":"domenic","email":"d@domenic.me"},"directories":{},"maintainers":[{"name":"domenic","email":""},{"name":"joris-van-der-wel","email":"joris@jorisvanderwel.com"},{"name":"sebmaster","email":""},{"name":"timothygu","email":"timothygu99@gmail.com"},{"name":"tmpvar","email":"tmpvar@gmail.com"},{"name":"zirro","email":"code@zirro.se"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/data-urls_4.0.0_1672712869607_0.6585516810430649"},"_hasShrinkwrap":false,"_cnpmcore_publish_time":"2023-01-03T02:30:40.779Z","publish_time":1672712869741,"_cnpm_publish_time":1672712869741},"3.0.2":{"name":"data-urls","description":"Parses data: URLs","keywords":["data url","data uri","data:","http","fetch","whatwg"],"version":"3.0.2","author":{"name":"Domenic Denicola","email":"d@domenic.me","url":"https://domenic.me/"},"license":"MIT","repository":{"type":"git","url":"git+https://github.com/jsdom/data-urls.git"},"main":"lib/parser.js","scripts":{"test":"jest","coverage":"jest --coverage","lint":"eslint .","pretest":"node scripts/get-latest-platform-tests.js"},"dependencies":{"abab":"^2.0.6","whatwg-mimetype":"^3.0.0","whatwg-url":"^11.0.0"},"devDependencies":{"@domenic/eslint-config":"^2.0.0","eslint":"^8.14.0","jest":"^27.5.1","minipass-fetch":"^2.1.0"},"engines":{"node":">=12"},"jest":{"coverageDirectory":"coverage","coverageReporters":["lcov","text-summary"],"testEnvironment":"node","testMatch":["<rootDir>/test/**/*.js"],"coveragePathIgnorePatterns":["<rootDir>/node_modules/(?!(abab/lib/atob.js))"]},"gitHead":"f061877a7d517b3160ce7a7752fee0262308886c","bugs":{"url":"https://github.com/jsdom/data-urls/issues"},"homepage":"https://github.com/jsdom/data-urls#readme","_id":"data-urls@3.0.2","_nodeVersion":"16.14.2","_npmVersion":"8.5.0","dist":{"shasum":"9cf24a477ae22bcef5cd5f6f0bfbc1d2d3be9143","size":3565,"noattachment":false,"key":"/data-urls/-/data-urls-3.0.2.tgz","tarball":"http://registry.cnpm.dingdandao.com/data-urls/download/data-urls-3.0.2.tgz"},"_npmUser":{"name":"domenic","email":"d@domenic.me"},"directories":{},"maintainers":[{"name":"domenic","email":""},{"name":"joris-van-der-wel","email":"joris@jorisvanderwel.com"},{"name":"sebmaster","email":""},{"name":"timothygu","email":"timothygu99@gmail.com"},{"name":"tmpvar","email":"tmpvar@gmail.com"},{"name":"zirro","email":"code@zirro.se"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/data-urls_3.0.2_1650847515533_0.35206335376716824"},"_hasShrinkwrap":false,"_cnpmcore_publish_time":"2022-04-25T00:45:20.278Z","publish_time":1650847515708,"_cnpm_publish_time":1650847515708},"3.0.1":{"name":"data-urls","description":"Parses data: URLs","keywords":["data url","data uri","data:","http","fetch","whatwg"],"version":"3.0.1","author":{"name":"Domenic Denicola","email":"d@domenic.me","url":"https://domenic.me/"},"license":"MIT","repository":{"type":"git","url":"git+https://github.com/jsdom/data-urls.git"},"main":"lib/parser.js","scripts":{"test":"jest","coverage":"jest --coverage","lint":"eslint .","pretest":"node scripts/get-latest-platform-tests.js"},"dependencies":{"abab":"^2.0.3","whatwg-mimetype":"^3.0.0","whatwg-url":"^10.0.0"},"devDependencies":{"@domenic/eslint-config":"^1.4.0","eslint":"^7.32.0","jest":"^27.2.4","minipass-fetch":"^1.4.1"},"engines":{"node":">=12"},"jest":{"coverageDirectory":"coverage","coverageReporters":["lcov","text-summary"],"testEnvironment":"node","testMatch":["<rootDir>/test/**/*.js"],"coveragePathIgnorePatterns":["<rootDir>/node_modules/(?!(abab/lib/atob.js))"]},"gitHead":"fb6402d4529a23ceeebaa82876cf6d473c3f936d","bugs":{"url":"https://github.com/jsdom/data-urls/issues"},"homepage":"https://github.com/jsdom/data-urls#readme","_id":"data-urls@3.0.1","_nodeVersion":"16.9.1","_npmVersion":"7.21.1","dist":{"shasum":"597fc2ae30f8bc4dbcf731fcd1b1954353afc6f8","size":3567,"noattachment":false,"key":"/data-urls/-/data-urls-3.0.1.tgz","tarball":"http://registry.cnpm.dingdandao.com/data-urls/download/data-urls-3.0.1.tgz"},"_npmUser":{"name":"domenic","email":"d@domenic.me"},"directories":{},"maintainers":[{"name":"domenic","email":""},{"name":"joris-van-der-wel","email":"joris@jorisvanderwel.com"},{"name":"sebmaster","email":""},{"name":"timothygu","email":"timothygu99@gmail.com"},{"name":"tmpvar","email":"tmpvar@gmail.com"},{"name":"zirro","email":"code@zirro.se"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/data-urls_3.0.1_1633539780228_0.7045257317898264"},"_hasShrinkwrap":false,"publish_time":1633539780337,"_cnpm_publish_time":1633539780337},"3.0.0":{"name":"data-urls","description":"Parses data: URLs","keywords":["data url","data uri","data:","http","fetch","whatwg"],"version":"3.0.0","author":{"name":"Domenic Denicola","email":"d@domenic.me","url":"https://domenic.me/"},"license":"MIT","repository":{"type":"git","url":"git+https://github.com/jsdom/data-urls.git"},"main":"lib/parser.js","scripts":{"test":"jest","coverage":"jest --coverage","lint":"eslint .","pretest":"node scripts/get-latest-platform-tests.js"},"dependencies":{"abab":"^2.0.3","whatwg-mimetype":"^2.3.0","whatwg-url":"^9.0.0"},"devDependencies":{"@domenic/eslint-config":"^1.2.0","eslint":"^7.29.0","jest":"^27.0.5","node-fetch":"^2.6.1"},"engines":{"node":">=12"},"jest":{"coverageDirectory":"coverage","coverageReporters":["lcov","text-summary"],"testEnvironment":"node","testMatch":["<rootDir>/test/**/*.js"],"coveragePathIgnorePatterns":["<rootDir>/node_modules/(?!(abab/lib/atob.js))"]},"gitHead":"32acfcccdce72dd5e3932935296e3778ce62aa7d","bugs":{"url":"https://github.com/jsdom/data-urls/issues"},"homepage":"https://github.com/jsdom/data-urls#readme","_id":"data-urls@3.0.0","_nodeVersion":"16.4.0","_npmVersion":"7.18.1","dist":{"shasum":"3ff551c986d7c6234a0ac4bbf20a269e1cd6b378","size":3578,"noattachment":false,"key":"/data-urls/-/data-urls-3.0.0.tgz","tarball":"http://registry.cnpm.dingdandao.com/data-urls/download/data-urls-3.0.0.tgz"},"_npmUser":{"name":"domenic","email":"d@domenic.me"},"directories":{},"maintainers":[{"name":"domenic","email":""},{"name":"joris-van-der-wel","email":"joris@jorisvanderwel.com"},{"name":"sebmaster","email":""},{"name":"timothygu","email":"timothygu99@gmail.com"},{"name":"tmpvar","email":"tmpvar@gmail.com"},{"name":"zirro","email":"code@zirro.se"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/data-urls_3.0.0_1626721665395_0.1851254701290712"},"_hasShrinkwrap":false,"publish_time":1626721665540,"_cnpm_publish_time":1626721665540},"2.0.0":{"name":"data-urls","description":"Parses data: URLs","keywords":["data url","data uri","data:","http","fetch","whatwg"],"version":"2.0.0","author":{"name":"Domenic Denicola","email":"d@domenic.me","url":"https://domenic.me/"},"license":"MIT","repository":{"type":"git","url":"git+https://github.com/jsdom/data-urls.git"},"main":"lib/parser.js","scripts":{"test":"jest","coverage":"jest --coverage","lint":"eslint .","pretest":"node scripts/get-latest-platform-tests.js"},"dependencies":{"abab":"^2.0.3","whatwg-mimetype":"^2.3.0","whatwg-url":"^8.0.0"},"devDependencies":{"eslint":"^6.8.0","jest":"^24.9.0","request":"^2.88.0"},"engines":{"node":">=10"},"jest":{"coverageDirectory":"coverage","coverageReporters":["lcov","text-summary"],"testEnvironment":"node","testMatch":["<rootDir>/test/**/*.js"],"coveragePathIgnorePatterns":["<rootDir>/node_modules/(?!(abab/lib/atob.js))"]},"gitHead":"f7d60e8f5f990ebbddbea956dd561870b5370445","bugs":{"url":"https://github.com/jsdom/data-urls/issues"},"homepage":"https://github.com/jsdom/data-urls#readme","_id":"data-urls@2.0.0","_nodeVersion":"12.1.0","_npmVersion":"6.9.0","dist":{"shasum":"156485a72963a970f5d5821aaf642bef2bf2db9b","size":3562,"noattachment":false,"key":"/data-urls/-/data-urls-2.0.0.tgz","tarball":"http://registry.cnpm.dingdandao.com/data-urls/download/data-urls-2.0.0.tgz"},"maintainers":[{"name":"domenic","email":""},{"name":"joris-van-der-wel","email":"joris@jorisvanderwel.com"},{"name":"sebmaster","email":""},{"name":"timothygu","email":"timothygu99@gmail.com"},{"name":"tmpvar","email":"tmpvar@gmail.com"},{"name":"zirro","email":"code@zirro.se"}],"_npmUser":{"name":"domenic","email":"d@domenic.me"},"directories":{},"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/data-urls_2.0.0_1577997239716_0.9784558077583854"},"_hasShrinkwrap":false,"publish_time":1577997239814,"_cnpm_publish_time":1577997239814},"1.1.0":{"name":"data-urls","description":"Parses data: URLs","keywords":["data url","data uri","data:","http","fetch","whatwg"],"version":"1.1.0","author":{"name":"Domenic Denicola","email":"d@domenic.me","url":"https://domenic.me/"},"license":"MIT","repository":{"type":"git","url":"git+https://github.com/jsdom/data-urls.git"},"main":"lib/parser.js","scripts":{"test":"jest","coverage":"jest --coverage","lint":"eslint .","pretest":"node scripts/get-latest-platform-tests.js"},"devDependencies":{"eslint":"^5.7.0","jest":"^23.6.0","request":"^2.88.0"},"jest":{"coverageDirectory":"coverage","coverageReporters":["lcov","text-summary"],"testEnvironment":"node","testMatch":["<rootDir>/test/**/*.js"],"coveragePathIgnorePatterns":["<rootDir>/node_modules/(?!(abab/lib/atob.js))"]},"dependencies":{"abab":"^2.0.0","whatwg-mimetype":"^2.2.0","whatwg-url":"^7.0.0"},"gitHead":"f42daf4c31a7ed00295993990ebbd2901bee168f","bugs":{"url":"https://github.com/jsdom/data-urls/issues"},"homepage":"https://github.com/jsdom/data-urls#readme","_id":"data-urls@1.1.0","_npmVersion":"6.4.1","_nodeVersion":"10.12.0","_npmUser":{"name":"domenic","email":"d@domenic.me"},"dist":{"shasum":"15ee0582baa5e22bb59c77140da8f9c76963bbfe","size":3550,"noattachment":false,"key":"/data-urls/-/data-urls-1.1.0.tgz","tarball":"http://registry.cnpm.dingdandao.com/data-urls/download/data-urls-1.1.0.tgz"},"maintainers":[{"name":"domenic","email":""},{"name":"joris-van-der-wel","email":"joris@jorisvanderwel.com"},{"name":"sebmaster","email":""},{"name":"timothygu","email":"timothygu99@gmail.com"},{"name":"tmpvar","email":"tmpvar@gmail.com"},{"name":"zirro","email":"code@zirro.se"}],"directories":{},"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/data-urls_1.1.0_1540559128977_0.9896566440878478"},"_hasShrinkwrap":false,"publish_time":1540559129091,"_cnpm_publish_time":1540559129091},"1.0.1":{"name":"data-urls","description":"Parses data: URLs","keywords":["data url","data uri","data:","http","fetch","whatwg"],"version":"1.0.1","author":{"name":"Domenic Denicola","email":"d@domenic.me","url":"https://domenic.me/"},"license":"MIT","repository":{"type":"git","url":"git+https://github.com/jsdom/data-urls.git"},"main":"lib/parser.js","files":["lib/"],"scripts":{"test":"jest","coverage":"jest --coverage","lint":"eslint .","pretest":"node scripts/get-latest-platform-tests.js"},"devDependencies":{"eslint":"^5.4.0","jest":"^23.5.0","request":"^2.88.0"},"jest":{"coverageDirectory":"coverage","coverageReporters":["lcov","text-summary"],"testEnvironment":"node","testMatch":["<rootDir>/test/**/*.js"]},"dependencies":{"abab":"^2.0.0","whatwg-mimetype":"^2.1.0","whatwg-url":"^7.0.0"},"gitHead":"ef1f61395cf0afdbbf04274509332becdd7eb4e1","bugs":{"url":"https://github.com/jsdom/data-urls/issues"},"homepage":"https://github.com/jsdom/data-urls#readme","_id":"data-urls@1.0.1","_npmVersion":"6.2.0","_nodeVersion":"10.8.0","_npmUser":{"name":"domenic","email":"d@domenic.me"},"dist":{"shasum":"d416ac3896918f29ca84d81085bc3705834da579","size":3498,"noattachment":false,"key":"/data-urls/-/data-urls-1.0.1.tgz","tarball":"http://registry.cnpm.dingdandao.com/data-urls/download/data-urls-1.0.1.tgz"},"maintainers":[{"name":"domenic","email":""},{"name":"joris-van-der-wel","email":"joris@jorisvanderwel.com"},{"name":"sebmaster","email":""},{"name":"timothygu","email":"timothygu99@gmail.com"},{"name":"tmpvar","email":"tmpvar@gmail.com"},{"name":"zirro","email":"code@zirro.se"}],"directories":{},"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/data-urls_1.0.1_1534627346113_0.8636024731783971"},"_hasShrinkwrap":false,"publish_time":1534627346198,"_cnpm_publish_time":1534627346198},"1.0.0":{"name":"data-urls","description":"Parses data: URLs","keywords":["data url","data uri","data:","http","fetch","whatwg"],"version":"1.0.0","author":{"name":"Domenic Denicola","email":"d@domenic.me","url":"https://domenic.me/"},"license":"MIT","repository":{"type":"git","url":"git+https://github.com/jsdom/data-urls.git"},"main":"lib/parser.js","files":["lib/"],"scripts":{"test":"jest","coverage":"jest --coverage","lint":"eslint .","pretest":"node scripts/get-latest-platform-tests.js"},"devDependencies":{"eslint":"^4.13.0","jest":"^21.2.1","request":"^2.83.0"},"jest":{"coverageDirectory":"coverage","coverageReporters":["lcov","text-summary"],"testEnvironment":"node","testMatch":["<rootDir>/test/**/*.js"]},"dependencies":{"abab":"^1.0.4","whatwg-mimetype":"^2.0.0","whatwg-url":"^6.4.0"},"gitHead":"bd0705722c8992f48c9a9e2aa15e24189164a9ed","bugs":{"url":"https://github.com/jsdom/data-urls/issues"},"homepage":"https://github.com/jsdom/data-urls#readme","_id":"data-urls@1.0.0","_npmVersion":"5.3.0","_nodeVersion":"8.2.1","_npmUser":{"name":"domenic","email":"d@domenic.me"},"dist":{"shasum":"24802de4e81c298ea8a9388bb0d8e461c774684f","size":3527,"noattachment":false,"key":"/data-urls/-/data-urls-1.0.0.tgz","tarball":"http://registry.cnpm.dingdandao.com/data-urls/download/data-urls-1.0.0.tgz"},"maintainers":[{"name":"domenic","email":""},{"name":"joris-van-der-wel","email":"joris@jorisvanderwel.com"},{"name":"sebmaster","email":""},{"name":"timothygu","email":"timothygu99@gmail.com"},{"name":"tmpvar","email":"tmpvar@gmail.com"},{"name":"zirro","email":"code@zirro.se"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/data-urls-1.0.0.tgz_1517437914250_0.16816337523050606"},"directories":{},"publish_time":1517437914529,"_hasShrinkwrap":false,"_cnpm_publish_time":1517437914529}},"readme":"# Parse `data:` URLs\n\nThis package helps you parse `data:` URLs [according to the WHATWG Fetch Standard](https://fetch.spec.whatwg.org/#data-urls):\n\n```js\nconst parseDataURL = require(\"data-urls\");\n\nconst textExample = parseDataURL(\"data:,Hello%2C%20World!\");\nconsole.log(textExample.mimeType.toString()); // \"text/plain;charset=US-ASCII\"\nconsole.log(textExample.body);                // Uint8Array(13) [ 72, 101, 108, 108, 111, 44, … ]\n\nconst htmlExample = parseDataURL(\"data:text/html,%3Ch1%3EHello%2C%20World!%3C%2Fh1%3E\");\nconsole.log(htmlExample.mimeType.toString()); // \"text/html\"\nconsole.log(htmlExample.body);                // Uint8Array(22) [ 60, 104, 49, 62, 72, 101, … ]\n\nconst pngExample = parseDataURL(\"data:image/png;base64,iVBORw0KGgoAAA\" +\n                                \"ANSUhEUgAAAAUAAAAFCAYAAACNbyblAAAAHElEQVQI12P4\" +\n                                \"//8/w38GIAXDIBKE0DHxgljNBAAO9TXL0Y4OHwAAAABJRU\" +\n                                \"5ErkJggg==\");\nconsole.log(pngExample.mimeType.toString()); // \"image/png\"\nconsole.log(pngExample.body);                // Uint8Array(85) [ 137, 80, 78, 71, 13, 10, … ]\n```\n\n## API\n\nThis package's main module's default export is a function that accepts a string and returns a `{ mimeType, body }` object, or `null` if the result cannot be parsed as a `data:` URL.\n\n- The `mimeType` property is an instance of [whatwg-mimetype](https://www.npmjs.com/package/whatwg-mimetype)'s `MIMEType` class.\n- The `body` property is a `Uint8Array` instance.\n\nAs shown in the examples above, you can easily get a stringified version of the MIME type using its `toString()` method. Read on for more on getting the stringified version of the body.\n\n### Decoding the body\n\nTo decode the body bytes of a parsed data URL, you'll need to use the `charset` parameter of the MIME type, if any. This contains an encoding [label](https://encoding.spec.whatwg.org/#label); there are [various possible labels](https://encoding.spec.whatwg.org/#names-and-labels) for a given encoding. You can use the [`TextDecoder`](https://developer.mozilla.org/en-US/docs/Web/API/TextDecoder) API for this:\n\n```js\nconst parseDataURL = require(\"data-urls\");\n\nconst dataURL = parseDataURL(arbitraryString);\n\n// If there's no charset parameter, e.g. if `arbitraryString` is `\"data:text/plain,H%C3%A9llo!\"`,\n// then let's guess UTF-8.\nconst encodingLabel = dataURL.mimeType.parameters.get(\"charset\") ?? \"utf-8\";\nconst decoder = new TextDecoder(encodingLabel);\n\nconst bodyDecoded = decoder.decode(dataURL.body);\n```\n\n(Note that as of the time of this writing in 2026-01, Node.js's built-in `TextDecoder` has many correctness bugs, so we suggest using the polyfill from the [`@exodus/bytes`](https://www.npmjs.com/package/@exodus/bytes) package until they are fixed.)\n\nUsing the parsed charset is quite important, since [the spec requires](https://fetch.spec.whatwg.org/#data-url-processor) that if no parseable MIME type is given, the default is `\"US-ASCII\"`, [aka windows-1252](https://encoding.spec.whatwg.org/#note-latin1-ascii)—not UTF-8, like you might asume. So for example, given an `arbitraryString` of `\"data:,H%E9llo!\"`, the above code snippet will correctly produce a `bodyDecoded` of `\"Héllo!\"` by using the windows-1252 decoder, whereas if you used a UTF-8 decoder you'd get back `\"H�llo!\"`.\n\n### Advanced functionality: parsing from a URL record\n\nIf you are using the [`whatwg-url`](https://www.npmjs.com/package/whatwg-url) package, you may already have a \"URL record\" object on hand, as produced by that package's `parseURL` export. In that case, you can use this package's `fromURLRecord` export to save a bit of work:\n\n```js\nconst { parseURL } = require(\"whatwg-url\");\nconst dataURLFromURLRecord = require(\"data-urls\").fromURLRecord;\n\nconst urlRecord = parseURL(\"data:,Hello%2C%20World!\");\nconst dataURL = dataURLFromURLRecord(urlRecord);\n```\n\nIn practice, we expect this functionality only to be used by consumers like [jsdom](https://www.npmjs.com/package/jsdom), which are using these packages at a very low level.\n","_attachments":{},"homepage":"https://github.com/jsdom/data-urls#readme","bugs":{"url":"https://github.com/jsdom/data-urls/issues"},"license":"MIT"}