{"_id":"@aaronsuuu/vue-ua","name":"@aaronsuuu/vue-ua","dist-tags":{"latest":"1.0.0"},"versions":{"1.0.0":{"name":"@aaronsuuu/vue-ua","version":"1.0.0","description":"User agent hook for Vue 3","main":"index.js","publishConfig":{"access":"public"},"scripts":{"test":"vitest"},"repository":{"type":"git","url":"git+https://github.com/aaronsuuu/vue-ua.git"},"author":{"name":"Aaronsuuu"},"license":"MIT","bugs":{"url":"https://github.com/aaronsuuu/vue-ua/issues"},"homepage":"https://github.com/aaronsuuu/vue-ua#readme","dependencies":{"@vue/test-utils":"^2.4.6","@vueuse/core":"^11.0.0","ua-parser-js":"^1.0.38","vue":"^3.4.38"},"devDependencies":{"jsdom":"^24.1.1","vitest":"^2.0.5"},"_id":"@aaronsuuu/vue-ua@1.0.0","gitHead":"bec3805480777f7d8b7fed25f74e3bf496e569be","_nodeVersion":"20.12.1","_npmVersion":"10.5.0","dist":{"integrity":"sha512-D9lCkeHnvx8CftDvpntYB+TY5zYp30jOLJZM+hFv3rVT5gzWRfChXDowBDyGu/Qv+cWf4xGn3fF4iW4PgwoDaw==","shasum":"f45386bbb11620be785f93c307cef1e74c9685c2","tarball":"https://registry.npmjs.org/@aaronsuuu/vue-ua/-/vue-ua-1.0.0.tgz","fileCount":8,"unpackedSize":6536,"signatures":[{"keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U","sig":"MEUCIQDSg9hK9NvO37h/UN2wsdw3s0IuLhw10Yh1jr4s/5yCzgIgfDnHqUiki0xRFPKqIlJqIFw4SLcCgADi/cY7n7Z0/XE="}]},"_npmUser":{"name":"aaronsuuu","email":"small12112000@gmail.com"},"directories":{},"maintainers":[{"name":"aaronsuuu","email":"small12112000@gmail.com"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages-npm-production","tmp":"tmp/vue-ua_1.0.0_1743583923465_0.09527467760313013"},"_hasShrinkwrap":false}},"time":{"created":"2025-04-02T08:52:03.385Z","1.0.0":"2025-04-02T08:52:03.679Z","modified":"2025-04-02T08:52:03.979Z"},"maintainers":[{"name":"aaronsuuu","email":"small12112000@gmail.com"}],"description":"User agent hook for Vue 3","homepage":"https://github.com/aaronsuuu/vue-ua#readme","repository":{"type":"git","url":"git+https://github.com/aaronsuuu/vue-ua.git"},"author":{"name":"Aaronsuuu"},"bugs":{"url":"https://github.com/aaronsuuu/vue-ua/issues"},"license":"MIT","readme":"# vue-ua\n\nVue User Agent Plugin is contain all the information about the user agent.It provides a simple API to get the user agent information in your Vue 3 application.\n\nUser agent information is reactive, it will update automatically when window resize or change.\nYou can use it in your template or script.\nEasy to switch the UI based on the user agent.\n\nIt's based on ua-parser-js and vueuse.\n\n## Installation\n\n```bash\nnpm install vue-ua\n```\n\n## Usage\n\n```vue\n<script setup>\nimport { useUserAgent } from \"vue-ua\";\nconst {\n  browser,\n  os,\n  device,\n\n  isChrome,\n  isSafari,\n  isFirefox,\n  isIE,\n  isEdge,\n\n  isAndroid,\n  isIOS,\n\n  isWindows,\n  isMacOS,\n  isLinux,\n\n  isDesktop,\n  isMobile,\n  isTablet,\n} = useUserAgent();\n</script>\n<template>\n  <div>\n    <div v-if=\"isMobile\">Mobile</div>\n    <div v-else-if=\"isDesktop\">Desktop</div>\n    <div v-else-if=\"isTablet\">Tablet</div>\n    <div v-else>Other</div>\n  </div>\n</template>\n```\n","readmeFilename":"README.md","_rev":"1-38de7864b9c42df7089633632de9ffd0"}