- Home /
Unity3d Webgl build and angularjs
hi everybody, i'm currently creating a project usin Angular 1.5.x. I'm trying to host the unity web build (WebGL) on one of my views. I ran into alot of different problems: - The build works when its served as a single html file from my localhost (I use Node.js and Express to implement it.) - Trying to edit the html rendered by Unity, I could not include the UnityLoader.js script (or any other script) because Angular ignores Script tags, and I can't load it to my main html file because the javascript just starts running. - I built an Angular directive that loads the unity UnityLoader.js dynamically and got the following error: - - I tried to put the 'module' object inside the loader script and got this error: -
Running out of options. any one had any luck implementing unity Webgl applications into an Angular.js page?
Answer by dgonzalezt · Jan 08, 2018 at 04:54 PM
@TheFrohlich I'm sorry to answer in this old post, but were you able to run Unity webgl in Angular?. I am trying to make it work in a project of Angular 5 and I get this error "ERROR ReferenceError: UnityLoader is not defined".
@dgonzalezt I am still facing this issue while integrating Unity WebGL build to Angular 5 project. Have you succeeded in this? I need to load UnityLoader.js file at the component but I'm not able do this.
I also am dying to know how to get this going in Angular 5.... it says UnityLoader not defined even though I imported it from a valid path.