Reversible Migration
JuliusBrussee/caveman
Implement reversible compatibility-safe transitions. Use for schema, data, API, protocol, configuration, or dependency migrations requiring rollback and…
Guide for migrating Chromium WebUI components from Polymer to Lit.
$ npx skills add nwjs/chromium.src --skill webui-lit-migration -a claude-codeProject install by default; add -g for ~/.claude/skills/.
$ gh skill install nwjs/chromium.src webui-lit-migration --agent claude-codeProject scope by default; add --scope user for a personal install. Needs GitHub CLI 2.90.0 or later (public preview).
$ git clone --depth 1 https://github.com/nwjs/chromium.src.git skills-src && mkdir -p .claude/skills && cp -r skills-src/agents/skills/webui-lit-migration .claude/skills/webui-lit-migration && rm -rf skills-srcUse ~/.claude/skills/ instead of .claude/skills for a personal install. The folder must contain SKILL.md.
Claude Code skills documentation · loads skills from .claude/skills/
Install the "webui-lit-migration" agent skill from https://github.com/nwjs/chromium.src/tree/main/agents/skills/webui-lit-migration into .claude/skills/webui-lit-migration/ in this project. Copy the whole folder (SKILL.md and every file beside it), keep the folder name "webui-lit-migration", then confirm the skill loads.Claude Code copies the folder itself, the same result as the manual copy. Check what it changed before you commit it.
$skill-installer install https://github.com/nwjs/chromium.src/tree/main/agents/skills/webui-lit-migrationType this inside Codex. $skill-installer <name> installs a curated skill from openai/skills. The installer writes to $CODEX_HOME/skills (default ~/.codex/skills). Restart Codex if the skill does not show up.
$ npx skills add nwjs/chromium.src --skill webui-lit-migration -a codexProject install goes to .agents/skills/; add -g for ~/.codex/skills/.
$ gh skill install nwjs/chromium.src webui-lit-migration --agent codexProject scope by default (.agents/skills/); add --scope user for a personal install.
$ git clone --depth 1 https://github.com/nwjs/chromium.src.git skills-src && mkdir -p .agents/skills && cp -r skills-src/agents/skills/webui-lit-migration .agents/skills/webui-lit-migration && rm -rf skills-srcUse ~/.agents/skills/ instead of .agents/skills for a personal install.
Codex skills documentation · loads skills from .agents/skills/
Install the "webui-lit-migration" agent skill from https://github.com/nwjs/chromium.src/tree/main/agents/skills/webui-lit-migration into .agents/skills/webui-lit-migration/ in this project. Copy the whole folder (SKILL.md and every file beside it), keep the folder name "webui-lit-migration", then confirm the skill loads.Codex copies the folder itself, the same result as the manual copy. Check what it changed before you commit it.
$ npx skills add nwjs/chromium.src --skill webui-lit-migration -a cursorProject install goes to .agents/skills/; add -g for ~/.cursor/skills/.
$ gh skill install nwjs/chromium.src webui-lit-migration --agent cursorProject scope by default (.agents/skills/); add --scope user for a personal install.
$ git clone --depth 1 https://github.com/nwjs/chromium.src.git skills-src && mkdir -p .cursor/skills && cp -r skills-src/agents/skills/webui-lit-migration .cursor/skills/webui-lit-migration && rm -rf skills-srcUse ~/.cursor/skills/ instead of .cursor/skills for a personal install.
Cursor skills documentation · loads skills from .cursor/skills/, .agents/skills/, .claude/skills/, .codex/skills/
Install the "webui-lit-migration" agent skill from https://github.com/nwjs/chromium.src/tree/main/agents/skills/webui-lit-migration into .cursor/skills/webui-lit-migration/ in this project. Copy the whole folder (SKILL.md and every file beside it), keep the folder name "webui-lit-migration", then confirm the skill loads.Cursor copies the folder itself, the same result as the manual copy. Check what it changed before you commit it.
$ gemini skills install https://github.com/nwjs/chromium.src.git --path agents/skills/webui-lit-migration--scope user (default) or --scope workspace; --path is the subfolder of the repo that holds the skill; --consent skips the security confirmation prompt.
$ npx skills add nwjs/chromium.src --skill webui-lit-migration -a gemini-cliProject install goes to .agents/skills/; add -g for ~/.gemini/skills/.
$ gh skill install nwjs/chromium.src webui-lit-migration --agent gemini-cliProject scope by default (.agents/skills/); add --scope user for a personal install.
$ git clone --depth 1 https://github.com/nwjs/chromium.src.git skills-src && mkdir -p .gemini/skills && cp -r skills-src/agents/skills/webui-lit-migration .gemini/skills/webui-lit-migration && rm -rf skills-srcUse ~/.gemini/skills/ instead of .gemini/skills for a personal install, then run /skills reload.
Gemini CLI skills documentation · loads skills from .gemini/skills/, .agents/skills/
Install the "webui-lit-migration" agent skill from https://github.com/nwjs/chromium.src/tree/main/agents/skills/webui-lit-migration into .gemini/skills/webui-lit-migration/ in this project. Copy the whole folder (SKILL.md and every file beside it), keep the folder name "webui-lit-migration", then confirm the skill loads.Gemini CLI copies the folder itself, the same result as the manual copy. Check what it changed before you commit it.
$ gh skill install nwjs/chromium.src webui-lit-migrationInstalls for Copilot at project scope by default; add --scope user for a personal install. Preview a skill first with gh skill preview. Needs GitHub CLI 2.90.0 or later (public preview).
$ npx skills add nwjs/chromium.src --skill webui-lit-migration -a github-copilotProject install goes to .agents/skills/; add -g for ~/.copilot/skills/.
$ git clone --depth 1 https://github.com/nwjs/chromium.src.git skills-src && mkdir -p .github/skills && cp -r skills-src/agents/skills/webui-lit-migration .github/skills/webui-lit-migration && rm -rf skills-srcUse ~/.copilot/skills/ instead of .github/skills for a personal install. Commit .github/skills so cloud agent and code review can use it.
GitHub Copilot skills documentation · loads skills from .github/skills/, .claude/skills/, .agents/skills/
Install the "webui-lit-migration" agent skill from https://github.com/nwjs/chromium.src/tree/main/agents/skills/webui-lit-migration into .github/skills/webui-lit-migration/ in this project. Copy the whole folder (SKILL.md and every file beside it), keep the folder name "webui-lit-migration", then confirm the skill loads.GitHub Copilot copies the folder itself, the same result as the manual copy. Check what it changed before you commit it.
$ npx skills add nwjs/chromium.src --skill webui-lit-migration -a opencodeOpenCode documents no install command of its own. Project install goes to .agents/skills/; add -g for ~/.config/opencode/skills/.
$ gh skill install nwjs/chromium.src webui-lit-migration --agent opencodeProject scope by default (.agents/skills/); add --scope user for a personal install.
$ git clone --depth 1 https://github.com/nwjs/chromium.src.git skills-src && mkdir -p .opencode/skills && cp -r skills-src/agents/skills/webui-lit-migration .opencode/skills/webui-lit-migration && rm -rf skills-srcUse ~/.config/opencode/skills/ instead of .opencode/skills for a personal install.
OpenCode skills documentation · loads skills from .opencode/skills/, .claude/skills/, .agents/skills/
Install the "webui-lit-migration" agent skill from https://github.com/nwjs/chromium.src/tree/main/agents/skills/webui-lit-migration into .opencode/skills/webui-lit-migration/ in this project. Copy the whole folder (SKILL.md and every file beside it), keep the folder name "webui-lit-migration", then confirm the skill loads.OpenCode copies the folder itself, the same result as the manual copy. Check what it changed before you commit it.
webui-lit-migrationGuide for migrating Chromium WebUI components from Polymer to Lit.
Webui Lit Migration is an agent skill from nwjs/chromium.src. Guide for migrating Chromium WebUI components from Polymer to Lit. Activate this skill if the user asks to migrate a file or component to Lit.
Its SKILL.md is about 2.3k tokens, which your agent loads only when the skill is triggered. The skill folder holds 3 other files, including scripts (for example `scripts/run_codemod_script.sh`).
The repository describes itself as: Chromium codebase with NW.js modifications. Based on https://chromium.googlesource.com/chromium/src.git. The licence is BSD-3-Clause.
6 steps, taken from the step headings in SKILL.md.
Read from SKILL.md and the folder at commit a9e8946. It shows what the files ask for, not the result of running them.
Pre-approves nothing: there is no allowed-tools line, so your agent's usual permission prompts apply.
From allowed-tools in the SKILL.md frontmatter.
Ships 1 file in scripts/ (Shell), which the agent can run.
From the folder's file list and the shell code blocks in SKILL.md.
No URLs in SKILL.md.
From URLs in SKILL.md, links to its own repository left out.
Names no API keys, tokens, secrets or passwords.
From names ending in _API_KEY, _TOKEN, _SECRET, _KEY or _PASSWORD in SKILL.md.
Webui Lit Migration loads about 2.3k tokens when it runs. Until then it costs about 41 tokens; SKILL.md has 973 words of instructions outside code blocks.
Estimates: characters ÷ 4, the usual rule of thumb; real counts depend on the model's tokenizer. Scripts and assets cost tokens only if the agent reads them.
The automated check found no risky patterns in SKILL.md.
Automated static check — not a guarantee. Review scripts before installing. It scans the text of SKILL.md for risky patterns (piping downloads into a shell, reading credential files, hidden Unicode, destructive commands); the scripts in this folder are not scanned.
The full file from nwjs/chromium.src at commit a9e8946, republished under its BSD-3-Clause licence (© nwjs). 973 words, ~2,283 tokens.
.claude/skills/webui-lit-migration/SKILL.md (or your agent's skills folder). This skill also uses 2 other files; get the full folder from GitHub.IMPORTANT: Always do this first, as it automates trivial migration steps.
Run the script in this skill's scripts directory. Pass the path to the Polymer
based element's TS class definition file as the parameter. Example:
./webui-lit-migration/scripts/run_codemod_script.sh
chrome/browser/resources/certificate_manager/certificate_entry.ts
Replace PolymerElement import The script replaces this import except in cases where multiple things are imported from Polymer. If an import from polymer_bundled.min.js is still present after running the script, remove it and add: import {CrLitElement} from '//resources/lit/v3_0/lit.rollup.js';
Update 'extends PolymerElement' The script will update this in the case that no mixins are used. If there is still a reference to PolymerElement: replace SomeMixin(PolymerElement) with SomeMixinLit(CrLitElement)
Address any "TODO: Port this observer to Lit" comments left by the migration script as follows: a. Examine the observer (e.g. 'onFooChanged_') method. If it does not reference the DOM, add the following in a willUpdate callback. If it does reference the DOM (e.g., this.shadowRoot or this.$), add this in a updated() lifecycle callback instead.
if (changedProperties.has('foo')) {
this.onFooChanged_();
}b. If the property being observed is protected or private, the
changedProperties lifecycle method parameter will require a cast:const changedPrivateProperties = changedProperties as Map<PropertyKey, unknown>;
if (changedPrivateProperties.has('myProperty_')) { ... }c. Remove the added TODO and the commented out observer line.observers: ['onFooOrBarChanged_(foo, bar)']Remove the line and for each observer listed, add to a lifecycle method as described for single property observers, but check changedProperties for any of the properties listed in the observer:
if (changedProperties.has('foo') || changedProperties.has('bar')) {
this.onFooOrBarChanged_();
}Replace
foo: {
type: String,
value: 'foo',
},
...
value: string;with
foo: {
type: String,
},
...
accessor value: string = 'foo';For uninitialized properties, if a TS compiler error is thrown on build, initialize to a dummy or default value rather than using a non-null assertion operator or changing the type definition.
If any imported style file does not exist, check if the Polymer version (same file path, but without _lit suffix) exists. If so, generate the Lit version as follows:
[shared_style]_style_lit.css.*_lit.css file.#type=style-lit in the metadata. Update any
imported and included styles to the lit version (e.g. cr_shared_style.css.js
import --> cr_shared_style_lit.css.js import, include="cr-shared-style"
becomes include="cr-shared-style-lit").*_style.css file, leaving only its]
metadata header and a comment:/* Purposefully empty since this style is generated at build time from the
* equivalent Lit version. */*_lit.css.js
and include it.*_lit.css to css_files.<template is="dom-if" if=[[someCondition]]> with conditional
rendering.${this.someCondition ? html`<conditionally-rendered-element>` : ''}<template is="dom-repeat" items=[[myItems]]> with map(): ${this.myItems.map((item, index) => html`<some-item data="${item}"></some-item>`)<cr-input .value="${this.value_}" @value-changed="${this.onValueChanged_}">Add a corresponding onFooChanged() method to the .ts file that updates the bound property from event.detail.value:
protected onFooChanged(e: CustomEvent<{value: string}>) {
this.value_ = e.detail.value;
}Update attribute bindings. Polymer uses "attr-name$=" syntax for attribute bindings. Replace this with "?attr-name=" if the attribute is a boolean, or "attr-name=" if the attribute is a string/number.
Update property bindings. Any other bindings that were bound using "property-name=" syntax should migrate to Lit's property syntax: ".propertyName=".
Look for properties that are passed to methods in the HTML. If the method is
used in multiple places in the template with different parameters or is not a
class method, keep the properties as parameters and add this. to reference
them. Ex:
Replace:
<div aria-label="${this.i18n('foo', someProp)}"></div>
<button>${this.i18n('buttonLabel', somOtherProp)}</button>with:
<div aria-label="${this.i18n('foo', this.someProp)}"></div>
<button>${this.i18n('buttonLabel', this.somOtherProp)}</button>If a method is a class member method used in a single location, remove the
property parameters in the template and change the method to reference them
directly. Ex: if getDivClass() is only used in this location, then:
Replace:
<div class="${this.getDivClass(someProp, someOtherProp)}">protected getDivClass(value: string, otherValue: string) {
return value + ' ' + otherValue;
}with
<div class="${this.getDivClass()}">protected getDivClass() {
return this.someProp + ' ' + this.someOtherProp;
}Find the BUILD.gn file referencing the old .html and .ts files. It should be in the same directory as the .ts file or in an ancestor directory. If you can't locate it, prompt the user for the BUILD.gn file to update.
.ts file from
web_component_files to ts_files.[component].html.ts file to ts_files..css and any new shared style
*_lit.css files to css_files.if (is_chromeos) { ... }).autoninja -C <out_folder> <migrating_directory>:resourcesAddress any errors. Note that error line numbers for TSC and eslint correspond to preprocessed code, not source code. Look at the line number, open the generated preprocessed file, which is at <build_dir>/gen/<migrating_directory>/preprocessed, look at the error line, and then find this line in the corresponding source file to fix it.
autoninja -C <out_folder> chrome browser_tests interactive_ui_tests** Important: Always re-build the full test target when debugging. ** Resources are served from .pak files that will not be updated properly without performing a full build.
Identify the test directory for the migrating WebUI. It should be located at chrome/test/data/webui/<path_from_chrome_browser_resources>/. E.g., tests for chrome/browser/resources/certificate_manager are at chrome/test/data/webui/certificate_manager. If no such directory is found, prompt the user to ask for the WebUI test directory.
Examine any .cc files found in the test directory to find the names of the TEST_F targets to gtest_filter for. By convention, .cc files ending in browsertest.cc or browser_tests.cc or similar will be run as part of the browser_tests target. .cc files ending in focus_test.cc or interactive_test.cc will be run as part of the interactive_ui_tests target.
Run all tests found in all .cc files in the WebUI's test directory and debug any test failures.
<out_folder>/browser_tests --gtest_filter=<TestNamePatternHere>
<out_folder>/interactive_ui_tests --gtest_filter=<TestNamePatternHere>© nwjs, BSD-3-Clause. Rendered from Markdown: HTML in the file is shown as text, images as links, and headings moved down two levels. Raw file
SKILL.md and 2 other files (scripts) in agents/skills/webui-lit-migration of nwjs/chromium.src.
Open the folder on GitHubat commit a9e8946
Webui Lit Migration next to the 5 skills that share the most tags, products or categories with it. Stars are the repository's; “used in” counts other GitHub owners with a copy.
| Skill | Stars | Used in | Tokens | Auto-check | Licence | Repo updated |
|---|---|---|---|---|---|---|
| Webui Lit Migration this skillnwjs/chromium.src | 160 | — | ~2.3k | Automated safety check: Pass | BSD-3-Clause | |
| Reversible MigrationJuliusBrussee/caveman | 110k | 1 repos | ~196 | Automated safety check: Pass | Apache-2.0 | |
| Database Migrationsaffaan-m/ECC | 275k | 4 repos | ~3k | Automated safety check: Pass | MIT | |
| Database Migrationsaffaan-m/ECC | 275k | 1 repos | ~2.4k | Automated safety check: Pass | MIT | |
| Safe Database Migration Patternsaffaan-m/ECC | 275k | — | ~3.3k | Automated safety check: Pass | MIT | |
| Migrate Createruvnet/ruflo | 74k | — | ~583 | Automated safety check: Notes | MIT |
JuliusBrussee/caveman
Implement reversible compatibility-safe transitions. Use for schema, data, API, protocol, configuration, or dependency migrations requiring rollback and…
affaan-m/ECC
Safe, reversible database migration patterns: forward-only production changes, expand-contract zero-downtime renames, concurrent indexes, batched backfills, and per-tool workflows for PostgreSQL…
affaan-m/ECC
Şema değişiklikleri, veri migration'ları, rollback'ler ve PostgreSQL, MySQL ve yaygın ORM'ler (Prisma, Drizzle, Django, TypeORM, golang-migrate) arasında sıfır kesinti deployment'ları için…
affaan-m/ECC
Rules and examples for safe, reversible schema changes in production: zero-downtime column and index changes, large data backfills and ORM migration workflows.
ruvnet/ruflo
Create a new sequentially numbered database migration with up/down SQL files
kortix-ai/suna
How to change the database schema in this repo. An agent skill from kortix-ai/suna.
nwjs/chromium.src
Extracts raw trace data from Perfetto traces, runs arbitrary SQL queries for custom follow-up analysis, and applies expert cognitive principles (Tiered Flow Analysis, Semantic Mismatch, Redundancy)…
nwjs/chromium.src
Autonomous multi-agent performance optimization loop for Chromium and V8.
nwjs/chromium.src
Automated Tracing & Performance Telemetry in Chromium using Perfetto and Telemetry benchmarks.
nwjs/chromium.src
Queries Chrome commit, version, release, and milestone metadata.
nwjs/chromium.src
Search and reference Chromium documentation from the local docs index, including design docs, APIs, and development guides.
nwjs/chromium.src
Diagnose Chromium GN dependency and include-visibility failures, including BUILD.gn deps/publicdeps, DEPS include rules, private headers, and circular dependencies.
Guide for migrating Chromium WebUI components from Polymer to Lit. src. Guide for migrating Chromium WebUI components from Polymer to Lit.
Run `npx skills add nwjs/chromium.src --skill webui-lit-migration -a claude-code`. Or copy the skill folder (agents/skills/webui-lit-migration in nwjs/chromium.src) into .claude/skills/webui-lit-migration in your project. Claude Code loads it when a task matches its description.
Run `npx skills add nwjs/chromium.src --skill webui-lit-migration -a codex`. Or copy the skill folder (agents/skills/webui-lit-migration in nwjs/chromium.src) into .agents/skills/webui-lit-migration in your project. Codex loads it when a task matches its description.
Cursor, Gemini CLI, GitHub Copilot and OpenCode also load SKILL.md folders. With the skills CLI, run `npx skills add nwjs/chromium.src --skill webui-lit-migration -a cursor` (or -a gemini-cli, github-copilot or opencode for the others). To copy it by hand, put the folder in .cursor/skills/webui-lit-migration, .gemini/skills/webui-lit-migration, .github/skills/webui-lit-migration and .opencode/skills/webui-lit-migration in your project.
Going by SKILL.md and its folder, Webui Lit Migration needs a shell for the scripts in its folder. Our summary lists: A Bash shell.
SKILL.md contains no URLs. Any network use would come from the scripts or tools the agent runs. This is read from the text; nothing was executed.
Our automated static check of SKILL.md found no risky patterns, such as piping downloads into a shell, reading credential files or hidden Unicode. It is not a guarantee. The check reads SKILL.md only: the scripts in the folder are not scanned, so read them before running anything.
Webui Lit Migration is published under the BSD-3-Clause licence (the repository's licence). It allows redistribution, so the full SKILL.md is shown on this page.
About 2.3k tokens (SKILL.md is roughly 9.1k characters). Agents keep only the skill's name and description in context until a task matches; then they load SKILL.md in full.
Skills that share tags, products or a category with Webui Lit Migration: Reversible Migration (JuliusBrussee/caveman, 110k stars), Database Migrations (affaan-m/ECC, 275k stars), Database Migrations (affaan-m/ECC, 275k stars) and Safe Database Migration Patterns (affaan-m/ECC, 275k stars). The comparison table on this page puts their stars, adoption, token cost, safety result and licence side by side.
nwjs (a GitHub organization) maintains it in nwjs/chromium.src, which has 160 GitHub stars. The repository holds 64 skills in this directory. The repository was last updated on October 3, 2026.
Source: nwjs/chromium.src on GitHub. Facts on this page come from the repository at the commit we read; the author's words are quoted as theirs.