{"name":"@vue/babel-sugar-v-model","version":"1.4.0","description":"Babel syntactic sugar for v-model support in Vue JSX","main":"dist/plugin.js","repository":{"type":"git","url":"git+https://github.com/vuejs/jsx.git#master"},"author":{"name":"Nick Messing","email":"dot.nick.dot.messing@gmail.com"},"license":"MIT","private":false,"publishConfig":{"access":"public"},"scripts":{"pretest:snapshot":"yarn build:test","test:snapshot":"nyc --reporter=html --reporter=text-summary ava -v test/snapshot.js","build:dependency":"cd ../babel-plugin-transform-vue-jsx && yarn build","pretest:functional":"yarn build:dependency && yarn build:test && nyc --reporter=html --reporter=text-summary babel test/functional.js --plugins ./dist/plugin.testing.js,../babel-plugin-transform-vue-jsx/dist/plugin.js,@babel/plugin-transform-arrow-functions --out-file test/functional-compiled.js","test:functional":"ava -v test/functional-compiled.js","build":"rollup -c","build:test":"rollup -c rollup.config.testing.js","test":"rm -rf coverage* && yarn test:snapshot && mv coverage coverage-snapshot && yarn test:functional && mv coverage coverage-functional","prepublish":"yarn build"},"devDependencies":{"@babel/cli":"^7.2.0","@babel/core":"^7.2.0","@babel/plugin-transform-arrow-functions":"^7.12.1","@babel/preset-env":"^7.2.0","@vue/test-utils":"1.0.0-beta.26","ava":"^0.25.0","jsdom":"^13.0.0","jsdom-global":"^3.0.2","nyc":"^13.1.0","rollup":"^0.67.4","rollup-plugin-babel":"4.0.3","rollup-plugin-istanbul":"^2.0.1","rollup-plugin-uglify-es":"^0.0.1","vue":"^2.5.17","vue-template-compiler":"^2.5.17"},"dependencies":{"@babel/plugin-syntax-jsx":"^7.2.0","@vue/babel-helper-vue-jsx-merge-props":"^1.4.0","@vue/babel-plugin-transform-vue-jsx":"^1.4.0","camelcase":"^5.0.0","html-tags":"^2.0.0","svg-tags":"^1.0.0"},"peerDependencies":{"@babel/core":"^7.0.0-0"},"nyc":{"exclude":["dist","test"]},"gitHead":"6566e12067f5d6c02d3849b574a1b84de5634008","bugs":{"url":"https://github.com/vuejs/jsx/issues"},"homepage":"https://github.com/vuejs/jsx/tree/master#readme","_id":"@vue/babel-sugar-v-model@1.4.0","_nodeVersion":"16.15.0","_npmVersion":"lerna/1.9.0/node@v16.15.0+arm64 (darwin)","dist":{"integrity":"sha512-0t4HGgXb7WHYLBciZzN5s0Hzqan4Ue+p/3FdQdcaHAb7s5D9WZFGoSxEZHrR1TFVZlAPu1bejTKGeAzaaG3NCQ==","shasum":"a51d986609f430c4f70ada3a93cc560a2970f720","tarball":"http://registry-npm.ywwl.com/@vue/babel-sugar-v-model/download/@vue/babel-sugar-v-model-1.4.0.tgz","fileCount":3,"unpackedSize":12346,"signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEYCIQDRA1Btkar5o6QS+DsNxXoJbayUJAbIvjchHIIw30zSngIhAK6zu//VACXow/eZAP2QOinc4To9FOXyMe3nm6NBOtl6"}],"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v4.10.10\r\nComment: https://openpgpjs.org\r\n\r\nwsFzBAEBCAAGBQJjB2McACEJED1NWxICdlZqFiEECWMYAoorWMhJKdjhPU1b\r\nEgJ2VmrnPg/8D8TTH+t7TQou8CMBSj+L84lvQCSPEEvVCc8MPzlRzWQIanqv\r\ns0gLjzWpAC+dlslgQ/EnkdFZKc6LamhnPgRFq14eaDsl5SpjkR1YE5jts/eQ\r\niUza2bPqcrPna3+eWx5+PK8ifX3GzqMKSGO2J8ai8LVn+SD5HNvAcTHYT92D\r\n4oIaohZviCAD5mDJNU8X9yg1r16K1/q4UzAtA078E8B7dCryiI+UAYGxP34s\r\nwRkH+prVk+PpwF5EluX44Jh/snVz0M5q5F5MBuP9fg5EIDQakuTtl25rGvAL\r\nBSTgCGIsngDL5E1ksMOrafWQVWcKUaXpZDCA2JlXwqrzN2pu2BMk4SL78MTY\r\nNMuR1z7CT42a6SElT0+yfMVxFGsxkK6mArr+Rdd7VKg1CM/yif1hFahWoViA\r\nVcha+1YhBgWMYPt0JtlvaVmfp8bFhiTtsZSVEyx4DUyOHz3B200UYsDyB9eJ\r\nofOW33XdfpdyOiCo5yXjKMR+DsJcmMQ4aO/V2ELUF6OTxh5xxH57TZhv9B01\r\naop9yG7MlrTCTpxRb66brryFLdiDlQSZkn2/T2T9oYH0jZvNF1Ulp9++RjvD\r\nbAXwai20WYI8It0zAesMX6V7bzzqLOba5MbxZGAcfjAg/QygkZhb2/nRQevc\r\nhXXPhHjf6flDlirKvdRd9KGzuGHnoxyOW8M=\r\n=12XE\r\n-----END PGP SIGNATURE-----\r\n","size":3695,"noattachment":false,"key":"/@vue/babel-sugar-v-model/-/@vue/babel-sugar-v-model-1.4.0.tgz"},"_npmUser":{"name":"soda","email":"haoqunjiang+npm@gmail.com"},"directories":{},"maintainers":[{"name":"nickmessing","email":"dot.nick.dot.messing@gmail.com"},{"name":"soda","email":"haoqunjiang+npm@gmail.com"},{"name":"yyx990803","email":"yyx990803@gmail.com"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/babel-sugar-v-model_1.4.0_1661428507890_0.03911892422792107"},"_hasShrinkwrap":false,"readme":"## @vue/babel-sugar-v-model\n\nSyntactic sugar for v-model in JSX.\n\n### Babel Compatibility Notes\n\n- This repo is only compatible with Babel 7.x, for 6.x please use [vuejs/babel-plugin-transform-vue-jsx](https://github.com/vuejs/babel-plugin-transform-vue-jsx)\n\n### Usage\n\nInstall the dependencies:\n\n```sh\n# for yarn:\nyarn add @vue/babel-sugar-v-model\n# for npm:\nnpm install @vue/babel-sugar-v-model --save\n```\n\nIn your `.babelrc`:\n\n```json\n{\n  \"plugins\": [\"@vue/babel-sugar-v-model\"]\n}\n```\n\nHowever it is recommended to use the [configurable preset](../babel-preset-jsx/README.md) instead.\n\n### Details\n\nThis plugin adds v-model to the JSX and tries to mirror the same behaviour as in vue-template-compiler, with a few differences:\n\n1.  You should use underscore (`_`) instead of dot (`.`) for modifiers (`vModel_trim={this.test}`)\n2.  It is recommended to use camelCase version of it (`vModel`) in JSX, but you can use kebab-case too (`v-model`).\n\n```js\nexport default {\n  data: () => ({\n    test: 'Hello World',\n  }),\n  render(h) {\n    return (\n      <div>\n        <input type=\"text\" vModel_trim={this.test} />\n        {this.test}\n      </div>\n    )\n  },\n}\n```\n","publish_time":1661428508119,"_cnpm_publish_time":1661428508119,"dist-tags":{"latest":"1.4.0"}}