Skip to content

getDeviceType is inconsistent #6

@nmiglio

Description

@nmiglio

I think there are a few issues with the device type detection. as it is now seems that everything smaller than "small" is detected as a watch. what is between small and large is a phone and what is bigger than large can be a desktop or a tablet.
Why use 2 breakpoints (small and large) to discriminate between 4 device types? And classifiyng everything smaller than 600 logical pixel as a watch is a bit too rough..

In addition I tested the library, setting the breakpoints at 600 and 900, having a tablet with 768 logical pixels. the result is that I cannot detect my device as a tablet. you can actually only force the tablet detection with sizes bigger than "large". this goes against some of the documentation of the library (and makes it not usable in my case - not at least as it is..).

I would suggest to use at least 3 breakpoints. maybe you can keep the option to force a tablet or a desktop with the biggest screen sizes, but is it useful?

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions