# nuxt-modules/device

Nuxt module for detecting device type.

Repository: https://github.com/nuxt-modules/device
Canonical: https://ross.abutalabs.com/products/nuxt-modules-device
Language: TypeScript
License: MIT
License Family: permissive
Topics: nuxt, nuxtjs, javascript
Last push: 2026-09-02T18:43:32+00:00

## Health v2 (maintenance only)
Score: 75/100 (v2, computed 2026-09-03T02:20:16.233290+00:00)
- activity 100, release rhythm 28, longevity 100
- inputs: {"age_days": 3190, "days_push": 0, "days_rel": 267, "gap_med": 223.5, "n_releases_24m": 3}
- flags: none
- formula: round(0.45*activity + 0.35*rhythm + 0.20*longevity); archived -> min(score, 10)

## Adoption (not part of the score)
Stars 1003, forks 54 (observed 2026-09-03T02:15:15.583581+00:00)

## What it is
A Nuxt module that detects the device type (desktop, mobile, tablet, OS, browser, crawler) from user-agent headers. It exposes flags via a $device helper and useDevice() composable, with CloudFront and Cloudflare header support.

## Use cases
- detect mobile vs desktop in a Nuxt app
- serve different layouts for mobile and desktop
- detect iOS or Android devices in Vue SSR
- detect bots and crawlers via user agent
- switch components based on device type
- device detection with Cloudflare or CloudFront headers

## When to choose
- you use Nuxt and need device-aware rendering or layouts
- you want simple boolean flags for device, OS, and browser detection
- you need crawler detection or CDN device-type header support

## When to avoid
- you need detailed device capability or hardware data
- your project is not Nuxt/Vue based
- you need client-side responsive behavior better handled with CSS media queries

## Facets
- artifact type: plugin
- maturity: active
- function: middleware, web-framework
- domain: web-development, frontend
- platform: -
- tags: nuxt, vue, device-detection, user-agent, responsive, nodejs, web-server

## Member repositories
- nuxt-modules/device (main) score 75

## Provenance
- Observed fields: from GitHub, fetched 2026-09-03T02:15:15.583581+00:00.
- Health v2: computed from the inputs above; adoption is never an input.
- Inferred fields (summary, facets, guidance): AI-extracted, prompt v1, taxonomy v1, on 2026-08-30T07:13:54.440631+00:00, confidence not recorded.
  - readme: https://github.com/nuxt-modules/device (fetched 2026-09-03T02:15:15.583581+00:00, sha 21d5aedee8db)
- Data as of 2026-08-30T08:39:29.467469+00:00.
