Skip to content

refactor(effects-manager): extract GLSL shaders to TypeScript modules (#886) - #973

Open
deveshbervar wants to merge 1 commit into
HSF:mainfrom
deveshbervar:refactor/shader-extraction-886-v2
Open

refactor(effects-manager): extract GLSL shaders to TypeScript modules (#886)#973
deveshbervar wants to merge 1 commit into
HSF:mainfrom
deveshbervar:refactor/shader-extraction-886-v2

Conversation

@deveshbervar

Copy link
Copy Markdown
Collaborator

Summary

Phase 2a of the refactoring proposed in #886.

Extracts the two inline GLSL shader strings fromeffects-manager.ts into dedicated TypeScript modules.

What changed

New files:

  • shaders/hover-vertex.ts — vertex shader as TS default export
  • shaders/hover-fragment.ts — fragment shader as TS default export

Modified:

  • effects-manager.ts — imports shaders from modules instead of defining them as inline class properties

Why TypeScript modules instead of .glsl files

Previous attempt (#933) used .glsl files with raw-loader but hit esbuild/Angular build pipeline issues in the Docker
smoke test. TypeScript modules work natively with all three build tools (webpack, esbuild, Jest) with zero configuration
changes.

Scope

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