MCPcopy Index your code
hub / github.com/SeleniumHQ/selenium-ide

github.com/SeleniumHQ/selenium-ide @v4.0.1-beta.14 sqlite

repository ↗ · DeepWiki ↗ · release v4.0.1-beta.14 ↗
1,957 symbols 4,781 edges 603 files 9 documented · 0%
README

Selenium IDE

logo

An integrated development environment for Selenium scripts Selenium IDE as an electron application written to enable recording and playback of selenium scripts.

Installation

Installation can be performed in a variety of ways:

  1. Prepackaged binaries are available to be installed directly as github releases.
  2. Selenium-ide can be installed via npm npm install -g selenium-ide and run via selenium-ide directly.
  3. The application can be built manually using the below instructions.

Building Manually

To build manually, you must have the below prerequisites installed and follow the steps afterward.

Prerequisites

Building

  1. git clone https://github.com/SeleniumHQ/selenium-ide - Clone the IDE repo
  2. cd selenium-ide - Navigate into the IDE folder
  3. pnpm -r i - Install dependencies
  4. pnpm run build - Build the app
  5. pnpm run start - Run the app

What now?

Here's a draft of the general tasks ahead. Feel free to pitch in and announce which you wish to take upon yourself:

  • Selectors accuracy - an option is ranking selectors - we can optimize selectors correctness and test stability by collecting as many attributes as we can per user event. The most likely properties will be used for the selectors, with fallback to the others.
  • Intelligent editing
  • Export to selenium code in different languages

Contributing

If you'd like to contribute to the codebase, start by building manually using the above commands. The below tips are meant to assist you as well.

  • If you'd like to iterate more quickly, yarn watch will facilitate near-realtime rebuilding for rapid iteration (make change -> yarn start -> test change)
  • To activate the devtools on an page, CommandOrControl+F12 or CommandOrControl+Option+I will open the devtools. For your convenience, the React Developer Tools are pre-installed in the electron environment.
  • VSCode has a defined workspace structure and run command, as well as file mappings to allow for breakpoints to work across sourcemaps for the main process.
  • The chrome dev tools are available at localhost:8315 to use if the inline devtools are not enough, although I'd highly advocate for the in window dev tools, since they have the React Developer Tools installed as well.

Questions or want to chat?

If you have questions, check out our FAQ.

You can also find us on the #selenium IRC channel, which is also available on Slack.

Architecture

The codebase is javascript, and relies heavily on the NodeJS, Electron, and React ecosystem. This is a collection of packages arranged in a monorepo config. Excepting the code-export packages, which are fully untyped, these packages are fully typed using Typescript.

Packages

These are the main packages. They're used to run the thing:

  • selenium-ide: Main Electron app. Built with webpack, react frontend. Communicates via the IPC protocols.

  • side-runner: NodeJS Task Runner. Built with typescript.

  • side-cli: Experimental cli using react and ink.

  • side-runtime: Playback system wrapper. Takes side files and executes them. Used by both selenium-ide and side-runner.

  • side-api: This is the api shape of selenium-ide. This is intended to be used to help share the api types with plugins in a lower footprint way.

  • side-model: This is used to provide metadata around the standard commands and argument types.

  • side-commons: This is like the typical utils/helpers folder, except meant to be shared across packages instead of just folders.

  • side-code-export: NodeJS transpiler for .side files. Used to export to other languages (csharp, java, javascript, python, ruby).

  • code-export-*: Code export format for various languages

Extension points exported contracts — how you extend this code

HoistedThings (Interface)
(no doc)
packages/side-runner/src/run.ts
StepProps (Interface)
(no doc)
packages/side-cli/src/components/step.tsx
ApiHoist (Interface)
(no doc)
packages/side-api/src/index.ts
Output (Interface)
(no doc)
packages/browser-info/src/sh.ts
RecorderSynchronizerInput (Interface)
(no doc)
packages/side-runtime/src/recording-syncronizer-webdriver.ts
EventEmitterLike (Interface)
(no doc)
packages/side-commons/src/types.ts
SideCodeExportCLIConfig (Interface)
(no doc)
packages/side-code-export/src/bin.ts
BrowserToDriver (Interface)
(no doc)
packages/get-driver/src/resolve-driver.ts

Core symbols most depended-on inside this repo

emit
called by 230
packages/side-code-export/src/code-export/hook.ts
push
called by 156
packages/side-runtime/src/playback-tree/state.ts
findElement
called by 76
packages/selenium-ide/src/browser/windows/PlaybackWindow/preload/locator-builders.ts
get
called by 68
packages/side-runtime/src/variables.ts
composePreprocessors
called by 62
packages/side-runtime/src/preprocessors.ts
play
called by 55
packages/side-runtime/src/playback.ts
preprocessArray
called by 44
packages/side-runtime/src/preprocessors.ts
validate
called by 43
packages/side-model/src/args/arg-type.ts

Shape

Function 1,288
Method 410
Interface 171
Class 87
Enum 1

Languages

TypeScript100%
Python1%

Modules by API surface

packages/selenium-ide/src/browser/windows/PlaybackWindow/preload/third-party/find-element.js146 symbols
packages/side-runtime/src/webdriver.ts112 symbols
packages/code-export-python-pytest/src/command.ts79 symbols
packages/code-export-csharp-commons/src/command.ts79 symbols
packages/code-export-ruby-rspec/src/command.ts78 symbols
packages/code-export-javascript-mocha/src/command.ts78 symbols
packages/code-export-java-junit/src/command.ts78 symbols
packages/selenium-ide/src/main/session/controllers/Windows/index.ts43 symbols
packages/side-runtime/src/playback.ts35 symbols
packages/side-code-export/src/code-export/emit.ts23 symbols
packages/selenium-ide/src/browser/windows/PlaybackWindow/preload/locator-builders.ts22 symbols
packages/side-runtime/src/playback-tree/command-node.ts20 symbols

Dependencies from manifests, versioned

@babel/core7.22.6 · 1×
@babel/eslint-parser7.22.6 · 1×
@babel/plugin-proposal-class-properties7.18.6 · 1×
@babel/plugin-proposal-export-namespace-from7.18.9 · 1×
@babel/preset-env7.22.6 · 1×
@babel/preset-typescript7.22.5 · 1×
@bazel/bazel2.1.0 · 1×
@bazel/buildifier6.1.2 · 1×
@bazel/ibazel0.16.2 · 1×
@bazel/typescript5.8.1 · 1×
@emotion/react11.11.1 · 1×
@emotion/styled11.11.0 · 1×

For agents

$ claude mcp add selenium-ide \
  -- python -m otcore.mcp_server <graph>

⬇ download graph artifact