diff --git a/README.md b/README.md index 5891b4c..f470b00 100644 --- a/README.md +++ b/README.md @@ -257,6 +257,16 @@ viewport.isLessThan('desktopWide') // Result: true. viewport.isLessThan('mobile') // Result: false. ``` +### `viewport.isLessOrEquals` +- Type: Boolean + +```js +// Example: viewport.breakpoint is "tablet". + +viewport.isLessOrEquals('tablet') // Result: true. +viewport.isLessOrEquals('mobile') // Result: false. +``` + ### `viewport.match` - Type: Boolean diff --git a/playground/pages/index.vue b/playground/pages/index.vue index 7d7a2e5..9d08964 100644 --- a/playground/pages/index.vue +++ b/playground/pages/index.vue @@ -19,6 +19,9 @@
isLessThan
→ {{ $viewport.isLessThan(breakpoint) }}
+ isLessOrEquals
→ {{ $viewport.isLessOrEquals(breakpoint) }}
+
isGreaterThan
→ {{ $viewport.isGreaterThan(breakpoint) }}