Skip to content

[🚀 Feature]: Add enum for _PageLoadStrategyDescriptor #13236

Closed
@M1troll

Description

@M1troll

Feature and motivation

Hi!

In my project, I've encountered a situation where I need to change the default page load strategy, but the only way to find the names of the available strategies is by searching the documentation or looking at the descriptor implementation.

I think it would be convenient to have an enum for these names. This would help with hints of available strategy names and save us from having to remember their full names. It would also be great to add info about difference between these strategies in the docstring of this class, as is done in the documentation.

Thanks!

Usage example

If enum is named PageLoadStrategy, I can easily use strategy name as follows:

from selenium import webdriver
from selenium.webdriver.chrome.options import Options, PageLoadStrategy

options = Options()
options.page_load_strategy = PageLoadStrategy.EAGER

Metadata

Metadata

Assignees

No one assigned

    Labels

    C-pyPython BindingsI-enhancementSomething could be betterR-help wantedIssues looking for contributions

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions