{"id":25032,"library":"broccoli-webgl-transpiler","title":"Broccoli WebGL Transpiler","description":"A Broccoli plugin that transpiles WebGL/GLSL source files into JavaScript strings. Version 0.0.1 is the initial and only release. As a minimal plugin, it simply compiles GLSL files into exported JS strings and renames them from `.glsl` to `.js`. It does not handle shader attachment or compilation at runtime. Compared to alternatives like `ember-cli-webgl`, it is lower-level and lacks Ember-specific integration. The project appears to be early-stage with limited adoption.","status":"active","version":"0.0.1","language":"javascript","source_language":"en","source_url":"https://github.com/anulman/broccoli-webgl-transpiler","tags":["javascript","broccoli-plugin","transpiler","webgl","glsl","opengl","js"],"install":[{"cmd":"npm install broccoli-webgl-transpiler","lang":"bash","label":"npm"},{"cmd":"yarn add broccoli-webgl-transpiler","lang":"bash","label":"yarn"},{"cmd":"pnpm add broccoli-webgl-transpiler","lang":"bash","label":"pnpm"}],"dependencies":[{"reason":"Extends Broccoli plugin base class for build pipeline integration","package":"broccoli-plugin","optional":false}],"imports":[{"note":"The package uses a default export. The require example in the README uses .default, but for ESM simply import default.","wrong":"const WebGLTranspiler = require('broccoli-webgl-transpiler').default;","symbol":"default","correct":"import WebGLTranspiler from 'broccoli-webgl-transpiler';"},{"note":"Named export is not available; only default export exists.","wrong":"const WebGLTranspiler = require('broccoli-webgl-transpiler');","symbol":"WebGLTranspiler","correct":"import { WebGLTranspiler } from 'broccoli-webgl-transpiler';"},{"note":"TypeScript types are not provided; this import is hypothetical.","wrong":"","symbol":"type BroccoliWebGLTranspilerOptions","correct":"import type { BroccoliWebGLTranspilerOptions } from 'broccoli-webgl-transpiler';"}],"quickstart":{"code":"const WebGLTranspiler = require('broccoli-webgl-transpiler');\nconst inputTree = 'path/to/glsl/files';\nconst webGLTree = new WebGLTranspiler(inputTree, {\n  annotation: 'compile my shaders'\n});\n// Then use webGLTree as input to another Broccoli plugin or build pipeline.","lang":"javascript","description":"Shows basic usage of broccoli-webgl-transpiler with a Broccoli tree."},"warnings":[{"fix":"Use higher-level library like ember-cli-webgl for automated shader compilation.","message":"Plugin only renames .glsl files to .js and compiles GLSL to exported JS strings; you must attach and compile shaders manually.","severity":"gotcha","affected_versions":"<=0.0.1"},{"fix":"Switch to actively maintained Broccoli plugin for GLSL.","message":"The npm package name 'broccoli-webgl-transpiler' has low download count and no recent updates; consider alternatives.","severity":"deprecated","affected_versions":">=0.0.0"}],"env_vars":null,"last_verified":"2026-05-01T00:00:00.000Z","next_check":"2026-07-30T00:00:00.000Z","problems":[{"fix":"const WebGLTranspiler = require('broccoli-webgl-transpiler').default;","cause":"Using require without .default when the package uses default export.","error":"TypeError: WebGLTranspiler is not a constructor"},{"fix":"Use broccoli.source or similar to create a tree from directory.","cause":"Passing a string path instead of a Broccoli node.","error":"Error: Input tree must be a Broccoli node"}],"ecosystem":"npm","meta_description":null,"install_score":null,"install_tag":null,"quickstart_score":null,"quickstart_tag":null}