jquery detect if pointer code example Example: js detect mouse support if (matchMedia('(pointer:fine)').matches) { // Device has a mouse }