DylanD Posted September 11, 2018 Share Posted September 11, 2018 Hey everyone, I have recently switched machines, from a mac to a windows machine. I am trying to set up my vscode enviroment and am having trouble with npm and its dependencies. I am still new to npm and am not sure how to go about this problem. Specifially i am using babylonjs:"^3.30-beta.5", babylonjs-gui:"^3.2.0", and babylonjs-materials:"3.3.0-beta.5". These are all in my package.json, when i was on my mac they all worked great together, although i had slowly upgraded from using babylonjs version 3.2.0, to all three of those dependencies. Now when i try to do npm install to get all of the packages i need on my new machine i get this error: npm WARN [email protected] requires a peer of babylonjs@>=3.2.0-alpha but none is installed. You must install peer dependencies yourself. npm WARN [email protected] requires a peer of babylonjs@>=3.2.0-alpha but none is installed. You must install peer dependencies yourself. Any ideas what im doing wrong? I tried installing both babylonjs-gui and babylonjs-materials with: npm install --save babylonjs babylonjs-gui npm install --save babylonjs babylonjs-materials But that didnt seem to help Quote Link to comment Share on other sites More sharing options...
DylanD Posted September 11, 2018 Author Share Posted September 11, 2018 just noticed in my git changes that somewhere when downloading and npm install ing it switch some stuff around in my package.json, thats gotta be the problem it switch my package.json from "babylonjs": "^3.3.0-alpha.13", "babylonjs-gui": "^3.2.0", "babylonjs-materials": "^3.3.0-alpha.13", to: "babylonjs": "^3.3.0-beta.5", "babylonjs-gui": "^3.2.0", "babylonjs-materials": "^3.3.0-beta.5", very strange, also im not sure how to change it back yet... edit: proboably just how to uninstall and install the correct packages edit2: that didnt work either, still get missing dependencies problem Quote Link to comment Share on other sites More sharing options...
DylanD Posted September 11, 2018 Author Share Posted September 11, 2018 its seems i have a lot more problems than this too. like vscode just not accepting my tsconfig.json looks like i have to figure most of this out myself Quote Link to comment Share on other sites More sharing options...
DylanD Posted September 11, 2018 Author Share Posted September 11, 2018 Alright so i still have the dependencies problem but it was as simple as updating vscode... it was on version 1.14, current version is 1.27 so that helped a lot. Not sure how much those dependencies are really impacting my game since i can build and run and it seems fine, except for a really weird change to how one of my shaders looks, which i need to look into and make another post for, could be my machine specific. For now its solved i guess, however i would still like to hear what you all think about just leaving the "missing" dependencies missing. (it says i need babylonjs3.2.0-alpha when i am using babylonjs3.3.0-alpha.13). Anyway thanks again for being my echo chamber i guess Quote Link to comment Share on other sites More sharing options...
brianzinn Posted September 11, 2018 Share Posted September 11, 2018 You should match the versions of all NPM projects for best results. Do you mind me asking why you are not updating GUI? For the shader I would create a new specific question, but make sure you have set the static Engine.ShadersRepository, if needed, and that files are being served to browser. trevordev 1 Quote Link to comment Share on other sites More sharing options...
trevordev Posted September 11, 2018 Share Posted September 11, 2018 Yep matching NPM versions is likely a good idea. Glad you managed to get it working. For me, in a new project running: npm install babylonjs babylonjs-gui babylonjs-materials or npm install babylonjs@preview babylonjs-gui@preview babylonjs-materials@preview for the latest version, does not spit out any dependency errors hcmetal 1 Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.