Advertisement
Guest User

Untitled

a guest
Dec 6th, 2016
74
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.45 KB | None | 0 0
  1. /**
  2. * To Allow relative template paths, we wrap the component in a function that receives the path to the
  3. * currently executing script (minus the actual filename)
  4. */
  5. (function (currentScriptPath) {
  6.  
  7. 'use strict';
  8.  
  9.  
  10.  
  11. })(
  12. (function () {
  13. var scripts = document.getElementsByTagName( 'script' );
  14. var currentScriptPath = scripts[scripts.length - 1].src;
  15. return currentScriptPath.substring(0, currentScriptPath.lastIndexOf('/'));
  16. })()
  17.  
  18. );
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement