Skip to content

Colocate node icons per node and copy them during build#16

Merged
mutec merged 1 commit into
mainfrom
build-routine-icons
Jul 12, 2026
Merged

Colocate node icons per node and copy them during build#16
mutec merged 1 commit into
mainfrom
build-routine-icons

Conversation

@mutec

@mutec mutec commented Jul 12, 2026

Copy link
Copy Markdown
Member

Was & Warum

Richtet Build-Script und -Routine am Template node-red-example aus und korrigiert die Icon-Platzierung.

Änderungen

  • build.js: neue copyIcons()-Funktion kopiert Icons pro Node von src/nodes/<node>/icons/dist/nodes/<node>/icons/. Tote buildPlugins()/buildThemes()-Stubs entfernt, Funktionen umbenannt (buildForm/copyLocales), durchgehend node:-Imports.
  • Icons pro Node statt zentral: icons/<node>.svgsrc/nodes/<node>/icons/<node>.svg; Top-Level icons/ entfernt. Die icon: "…​.svg"-Referenzen bleiben gültig (Node-RED registriert icons/-Ordner neben den Node-Dateien automatisch).
  • package.json files: icons raus, src + resources rein (analog Template); resources/.gitkeep als Platzhalter.

Verifiziert

npm run build läuft sauber, dist/nodes/*/icons/*.svg werden erzeugt.

Align build.js with the node-red-example template: add copyIcons() to
transfer each node's src/nodes/<node>/icons into dist/nodes/<node>/icons,
drop the unused plugin/theme stubs. Move the icons out of the central
icons/ directory into their nodes, ship src/resources instead.
@mutec
mutec merged commit 50ab9df into main Jul 12, 2026
13 checks passed
@mutec
mutec deleted the build-routine-icons branch July 12, 2026 09:29
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant