{"_id":"@bento/to-attribute-value","_rev":"3-d7fa7ba0bd84e1623c382620253a7daf","name":"@bento/to-attribute-value","dist-tags":{"latest":"0.1.1"},"versions":{"0.1.0":{"name":"@bento/to-attribute-value","version":"0.1.0","keywords":["attribute","bento","component","format","library","react","stringify","value"],"author":{"name":"GoDaddy Operating Company, LLC"},"license":"MIT","_id":"@bento/to-attribute-value@0.1.0","maintainers":[{"name":"3rdeden","email":"npmjs@3rd-Eden.com"},{"name":"rxmarbles","email":"rmarkins@gmail.com"},{"name":"kawikabader","email":"ekbader@gmail.com"}],"homepage":"https://github.com/godaddy/bento#readme","bugs":{"url":"https://github.com/godaddy/bento/issues"},"dist":{"shasum":"7671121858a0c3615fc38b004950707cb5b0299e","tarball":"https://registry.npmjs.org/@bento/to-attribute-value/-/to-attribute-value-0.1.0.tgz","fileCount":10,"integrity":"sha512-2sI+tt1TX89VPJKzqCtxIpZGlfm8S+t29O2aKeUnR/q79mBOAqjG/FFQ9PGQaGPuT/u2cygzZc6FPCOA13lpSg==","signatures":[{"sig":"MEYCIQD9u3s/ntvtsgt3Bvb6wzgT8/9Uc6+jdqtn/8pk/saYTwIhALKIaKVl0BoxnjKx8KU6gTZOItJDWkH5O7RO4MWzGPMy","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"}],"attestations":{"url":"https://registry.npmjs.org/-/npm/v1/attestations/@bento%2fto-attribute-value@0.1.0","provenance":{"predicateType":"https://slsa.dev/provenance/v1"}},"unpackedSize":25376},"main":"./dist/index.cjs","type":"module","types":"./dist/index.d.ts","module":"./dist/index.js","exports":{".":{"import":{"types":"./dist/index.d.ts","default":"./dist/index.js"},"require":{"types":"./dist/index.d.cts","default":"./dist/index.cjs"}},"./package.json":"./package.json"},"gitHead":"8cf6c3e7e24572c8b548fc4207e3af58bc3b5cc1","scripts":{"dev":"tsup-node --watch","lint":"biome lint && tsc --noEmit","test":"vitest --run","build":"tsup-node","pretest":"npm run build","posttest":"npm run lint","test:watch":"vitest"},"_npmUser":{"name":"kawikabader","email":"ekbader@gmail.com"},"repository":{"url":"git+https://github.com/godaddy/bento.git","type":"git"},"_npmVersion":"10.9.2","description":"Format a value as an HTML attribute value.","directories":{},"_nodeVersion":"23.11.1","dependencies":{"dashify":"^2.0.0"},"publishConfig":{"access":"public","registry":"https://registry.npmjs.org/"},"_hasShrinkwrap":false,"peerDependencies":{"react":"18.x || 19.x","react-dom":"18.x || 19.x"},"_npmOperationalInternal":{"tmp":"tmp/to-attribute-value_0.1.0_1761318930351_0.3260581857875955","host":"s3://npm-registry-packages-npm-production"}},"0.1.1":{"name":"@bento/to-attribute-value","version":"0.1.1","keywords":["attribute","bento","component","format","library","react","stringify","value"],"author":{"name":"GoDaddy Operating Company, LLC"},"license":"MIT","_id":"@bento/to-attribute-value@0.1.1","maintainers":[{"name":"3rdeden","email":"npmjs@3rd-Eden.com"},{"name":"rxmarbles","email":"rmarkins@gmail.com"},{"name":"kawikabader","email":"ekbader@gmail.com"}],"homepage":"https://github.com/godaddy/bento#readme","bugs":{"url":"https://github.com/godaddy/bento/issues"},"dist":{"shasum":"87507fbe74e01850a515407312e1809f2c6f4458","tarball":"https://registry.npmjs.org/@bento/to-attribute-value/-/to-attribute-value-0.1.1.tgz","fileCount":11,"integrity":"sha512-nIc+2emshJeh9jdnDQrjBWqGhjLx463FGxATQiYdN8SC+HYIdzw4QdzATuh0xS8U5sYXMIn6gpYVGLYU/ewbiA==","signatures":[{"sig":"MEUCIHjDFVuki1ukdKs7fJF9tf+iEDOcvI/JFdqh5cX+9vkVAiEA4VPXCy4nIulHRJe56lgyFVGo+2Cjo2FYC1GKfK7MV44=","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"}],"attestations":{"url":"https://registry.npmjs.org/-/npm/v1/attestations/@bento%2fto-attribute-value@0.1.1","provenance":{"predicateType":"https://slsa.dev/provenance/v1"}},"unpackedSize":26490},"main":"./dist/index.cjs","type":"module","types":"./dist/index.d.ts","module":"./dist/index.js","exports":{".":{"import":{"types":"./dist/index.d.ts","default":"./dist/index.js"},"require":{"types":"./dist/index.d.cts","default":"./dist/index.cjs"}},"./package.json":"./package.json"},"gitHead":"b630e17d1fad413043801e80ed1c1a0c5fe1d4b3","scripts":{"dev":"tsup-node --watch","lint":"biome lint && tsc --noEmit","test":"vitest --run","build":"tsup-node","pretest":"npm run build","posttest":"npm run lint","test:watch":"vitest","prepublishOnly":"node ../../scripts/compile-readme.ts"},"_npmUser":{"name":"kawikabader","email":"ekbader@gmail.com"},"repository":{"url":"git+https://github.com/godaddy/bento.git","type":"git"},"_npmVersion":"11.6.2","description":"Format a value as an HTML attribute value.","directories":{},"_nodeVersion":"23.11.1","dependencies":{"dashify":"^2.0.0"},"publishConfig":{"access":"public","registry":"https://registry.npmjs.org/"},"_hasShrinkwrap":false,"peerDependencies":{"react":"18.x || 19.x","react-dom":"18.x || 19.x"},"_npmOperationalInternal":{"tmp":"tmp/to-attribute-value_0.1.1_1762462136053_0.9417230420611893","host":"s3://npm-registry-packages-npm-production"}}},"time":{"created":"2025-10-24T15:15:30.293Z","modified":"2025-12-18T16:37:31.248Z","0.1.0":"2025-10-24T15:15:30.555Z","0.1.1":"2025-11-06T20:48:56.231Z"},"bugs":{"url":"https://github.com/godaddy/bento/issues"},"author":{"name":"GoDaddy Operating Company, LLC"},"license":"MIT","homepage":"https://github.com/godaddy/bento#readme","keywords":["attribute","bento","component","format","library","react","stringify","value"],"repository":{"url":"git+https://github.com/godaddy/bento.git","type":"git"},"description":"Format a value as an HTML attribute value.","maintainers":[{"email":"rmarkins@godaddy.com","name":"rmarkins"},{"email":"npmjs@3rd-Eden.com","name":"3rdeden"},{"email":"rmarkins@gmail.com","name":"rxmarbles"},{"email":"ekbader@gmail.com","name":"kawikabader"}],"readme":"# Attribute Value\n\nThe `@bento/to-attribute-value` package is a formatter that converts any given\nvalue into a string that can be used as an HTML attribute value.\n\n## Installation\n\n```shell\nnpm install --save @bento/to-attribute-value\n```\n\n## stringify\n\nThe package exposes the `stringify` function as the default export. The sole\npurpose of this function is to format any given value into a `string` that\nclosely resembles the value as if it was formatted as an HTML attribute value.\n\nThe function accepts the following arguments:\n\n```jsx\nimport { stringify } from '@bento/to-attribute-value';\n\nconsole.log(stringify({ hello: 'world'}));        // hello(world)\n```\n\nWe automatically format the `data` based on the type of the value given:\n\nAny unknown object is converted using `JSON.stringify`. In order for these\ncustom objects to be converted, they must have a `toJSON` method that returns a\nserializable object.\n\nThe value `false` is automatically converted to `undefined` to signal React that\nthe resulting attribute should not end up in the DOM.","readmeFilename":"README.md"}