muninn
GitHubExtensionWope
  • Introduction
  • Config
    • Basic
    • Selector
    • Array
    • Attribute
    • Type
    • Regex
    • Transform
    • Array Transform
    • Exist
    • Schema
    • Trim
    • Initial
    • Fill
    • HTML
    • Methods
Powered by GitBook
On this page

Was this helpful?

  1. Config

Exist

You can use exist to check if an element is on the page.

HTML
<div class="parent">
  <div class="website">www.test.com</div>
</div>
Config
{
    "website": {
        "selector": ".website",
        "exist": true,
    },
    "email": {
        "selector": ".email",
        "exist": true,
    },
}

// or

{
    "website": ".website | exist",
    "email": ".email | exist",
}
Output
{
    "website": true,
    "email": false,
}
PreviousArray TransformNextSchema

Last updated 2 years ago

Was this helpful?