diff --git a/package-lock.json b/package-lock.json
index 0bbad51e844badf4f715528348442ed89792212a..fef46892ec8d06f32d25cd623b14842a31d87b8e 100644
--- a/package-lock.json
+++ b/package-lock.json
@@ -518,7 +518,9 @@
       "requires": {
         "@tweenjs/tween.js": "^16.8.0",
         "browserify-css": "^0.8.2",
+        "debug": "github:ngokevin/debug#ef5f8e66d49ce8bc64c6f282c15f8b7164409e3a",
         "deep-assign": "^2.0.0",
+        "document-register-element": "github:dmarcos/document-register-element#8ccc532b7f3744be954574caf3072a5fd260ca90",
         "envify": "^3.4.1",
         "load-bmfont": "^1.2.3",
         "object-assign": "^4.0.1",
@@ -532,11 +534,7 @@
       "dependencies": {
         "debug": {
           "version": "github:ngokevin/debug#ef5f8e66d49ce8bc64c6f282c15f8b7164409e3a",
-          "from": "github:ngokevin/debug#ef5f8e66d49ce8bc64c6f282c15f8b7164409e3a"
-        },
-        "document-register-element": {
-          "version": "github:dmarcos/document-register-element#8ccc532b7f3744be954574caf3072a5fd260ca90",
-          "from": "github:dmarcos/document-register-element#8ccc532b7f3744be954574caf3072a5fd260ca90"
+          "from": "github:ngokevin/debug#noTimestamp"
         },
         "three": {
           "version": "0.94.0",
@@ -3906,6 +3904,10 @@
         "esutils": "^2.0.2"
       }
     },
+    "document-register-element": {
+      "version": "github:dmarcos/document-register-element#8ccc532b7f3744be954574caf3072a5fd260ca90",
+      "from": "github:dmarcos/document-register-element#8ccc532b7"
+    },
     "dom-converter": {
       "version": "0.1.4",
       "resolved": "https://registry.yarnpkg.com/dom-converter/-/dom-converter-0.1.4.tgz",
@@ -10542,6 +10544,12 @@
         }
       }
     },
+    "raw-loader": {
+      "version": "0.5.1",
+      "resolved": "https://registry.npmjs.org/raw-loader/-/raw-loader-0.5.1.tgz",
+      "integrity": "sha1-DD0L6u2KAclm2Xh793goElKpeao=",
+      "dev": true
+    },
     "react": {
       "version": "16.4.1",
       "resolved": "https://registry.yarnpkg.com/react/-/react-16.4.1.tgz",
diff --git a/package.json b/package.json
index d9e3d59c08ecdbf2adc92df5046aa149331bae1f..0462a0f4e7fa7fe89b737aefb0f7f210e8a26c88 100644
--- a/package.json
+++ b/package.json
@@ -87,6 +87,7 @@
     "htmlhint": "^0.9.13",
     "node-sass": "^4.9.3",
     "prettier": "^1.7.0",
+    "raw-loader": "^0.5.1",
     "rimraf": "^2.6.2",
     "sass-loader": "^6.0.7",
     "selfsigned": "^1.10.2",
diff --git a/src/components/media-highlight-frag.glsl b/src/components/media-highlight-frag.glsl
new file mode 100644
index 0000000000000000000000000000000000000000..e47db1ac09a41506fe2efb290cc169bcb0de7e05
--- /dev/null
+++ b/src/components/media-highlight-frag.glsl
@@ -0,0 +1,44 @@
+if (hubs_HighlightInteractorOne || hubs_HighlightInteractorTwo) {
+  mat4 it;
+  vec3 ip;
+  float dist1, dist2;
+
+  if (hubs_HighlightInteractorOne) {
+    it = hubs_InteractorOneTransform;
+    ip = vec3(it[3][0], it[3][1], it[3][2]);
+    dist1 = distance(hubs_WorldPosition, ip);
+  }
+
+  if (hubs_HighlightInteractorTwo) {
+    it = hubs_InteractorTwoTransform;
+    ip = vec3(it[3][0], it[3][1], it[3][2]);
+    dist2 = distance(hubs_WorldPosition, ip);
+  }
+
+  float ratio = 0.0;
+  float pulse = sin(hubs_Time / 1000.0) + 1.0;
+  float spacing = 0.5;
+  float line = spacing * pulse - spacing / 2.0;
+  float lineWidth= 0.01;
+  float mody = mod(hubs_WorldPosition.y, spacing);
+
+  if (-lineWidth + line < mody && mody < lineWidth + line) {
+    // Highlight with an animated line effect
+    ratio = 0.5;
+  } else {
+    // Highlight with a gradient falling off with distance.
+    if (hubs_HighlightInteractorOne) {
+      ratio = -min(1.0, pow(dist1 * (9.0 + 3.0 * pulse), 3.0)) + 1.0;
+    } 
+    if (hubs_HighlightInteractorTwo) {
+      ratio += -min(1.0, pow(dist2 * (9.0 + 3.0 * pulse), 3.0)) + 1.0;
+    }
+  }
+
+  ratio = min(1.0, ratio);
+
+  // Gamma corrected highlight color
+  vec3 highlightColor = vec3(0.184, 0.499, 0.933);
+
+  gl_FragColor.rgb = (gl_FragColor.rgb * (1.0 - ratio)) + (highlightColor * ratio);
+}
diff --git a/src/components/media-loader.js b/src/components/media-loader.js
index 1affa2140fd0f8c5429be35f51cf4048236c818d..e9393c7425e3170a92c9b24626b3f12ba975866e 100644
--- a/src/components/media-loader.js
+++ b/src/components/media-loader.js
@@ -1,6 +1,7 @@
 import { getBox, getScaleCoefficient } from "../utils/auto-box-collider";
 import { guessContentType, proxiedUrlFor, resolveUrl } from "../utils/media-utils";
 import { addAnimationComponents } from "../utils/animation";
+import mediaHighlightFrag from "./media-highlight-frag.glsl";
 
 import "three/examples/js/loaders/GLTFLoader";
 import loadingObjectSrc from "../assets/LoadingObject_Atom.glb";
@@ -58,56 +59,9 @@ function injectCustomShaderChunks(obj) {
       vlines.unshift("uniform bool hubs_HighlightInteractorTwo;");
       shader.vertexShader = vlines.join("\n");
 
-      const fchunk = `
-        if (hubs_HighlightInteractorOne || hubs_HighlightInteractorTwo) {
-          mat4 it;
-          vec3 ip;
-          float dist1, dist2;
-
-          if (hubs_HighlightInteractorOne) {
-            it = hubs_InteractorOneTransform;
-            ip = vec3(it[3][0], it[3][1], it[3][2]);
-            dist1 = distance(hubs_WorldPosition, ip);
-          }
-
-          if (hubs_HighlightInteractorTwo) {
-            it = hubs_InteractorTwoTransform;
-            ip = vec3(it[3][0], it[3][1], it[3][2]);
-            dist2 = distance(hubs_WorldPosition, ip);
-          }
-
-          float ratio = 0.0;
-          float pulse = sin(hubs_Time / 1000.0) + 1.0;
-          float spacing = 0.5;
-          float line = spacing * pulse - spacing / 2.0;
-          float lineWidth= 0.01;
-          float mody = mod(hubs_WorldPosition.y, spacing);
-
-          if (-lineWidth + line < mody && mody < lineWidth + line) {
-            // Highlight with an animated line effect
-            ratio = 0.5;
-          } else {
-            // Highlight with a gradient falling off with distance.
-            if (hubs_HighlightInteractorOne) {
-              ratio = -min(1.0, pow(dist1 * (9.0 + 3.0 * pulse), 3.0)) + 1.0;
-            } 
-            if (hubs_HighlightInteractorTwo) {
-              ratio += -min(1.0, pow(dist2 * (9.0 + 3.0 * pulse), 3.0)) + 1.0;
-            }
-          }
-
-          ratio = min(1.0, ratio);
-
-          // Gamma corrected highlight color
-          vec3 highlightColor = vec3(0.184, 0.499, 0.933);
-
-          gl_FragColor.rgb = (gl_FragColor.rgb * (1.0 - ratio)) + (highlightColor * ratio);
-        }
-      `;
-
       const flines = shader.fragmentShader.split("\n");
       const findex = flines.findIndex(line => fragRegex.test(line));
-      flines.splice(findex + 1, 0, fchunk);
+      flines.splice(findex + 1, 0, mediaHighlightFrag);
       flines.unshift("varying vec3 hubs_WorldPosition;");
       flines.unshift("uniform bool hubs_HighlightInteractorOne;");
       flines.unshift("uniform mat4 hubs_InteractorOneTransform;");
diff --git a/webpack.config.js b/webpack.config.js
index beeda9ac11e1722d48dc8de58d8ee262776ba4f1..d8e603694b197afa4152b9696062e727a375da87 100644
--- a/webpack.config.js
+++ b/webpack.config.js
@@ -154,6 +154,10 @@ module.exports = (env, argv) => ({
             context: path.join(__dirname, "src")
           }
         }
+      },
+      {
+        test: /\.(glsl)$/,
+        use: { loader: "raw-loader" }
       }
     ]
   },