brianzinn Posted September 28, 2017 Share Posted September 28, 2017 In my tsconfig.json I have "strictNullChecks": true That won't let me have something like: function unsetParent(mesh: AbstractMash) { mesh.setParent(null); } Error TS2345 (TS) Argument of type 'null' is not assignable to parameter of type 'AbstractMesh'. I didn't see a tsconfig in BabylonJS project. Seems like it should be setParent(mesh: AbstractMesh | null){...}? Or is it just not support to have strictNullChecks. Quote Link to comment Share on other sites More sharing options...
RaananW Posted September 28, 2017 Share Posted September 28, 2017 Setting this will require a lot more than this change. The flag strickNullChecks is relatively new and was therefore not used when Babylon was first developed. We will need a lot more | null in a lot of other places brianzinn 1 Quote Link to comment Share on other sites More sharing options...
brianzinn Posted September 28, 2017 Author Share Posted September 28, 2017 That's what I figured - thanks for confirming. I've seen it in a few other places in BabylonJS, so have just disabled it. What I've noticed is that having it enabled cascades changes, so it's probably a fair amount of effort to fix. Quote Link to comment Share on other sites More sharing options...
brianzinn Posted October 23, 2017 Author Share Posted October 23, 2017 @Deltakosh - Just noticing a lot of checkins lately for strictNullChecks - are you working towards having the entire library compatible? It seems like a good idea (and it is), but it's a lot of cascading tedious changes Quote Link to comment Share on other sites More sharing options...
RaananW Posted October 23, 2017 Share Posted October 23, 2017 soon, soon Quote Link to comment Share on other sites More sharing options...
GameMonetize Posted October 23, 2017 Share Posted October 23, 2017 I'm just dying doing it But I know it is a good idea. Slower than expected but hopefully I will soon be able to turn the option on on the repo brianzinn 1 Quote Link to comment Share on other sites More sharing options...
RaananW Posted October 23, 2017 Share Posted October 23, 2017 hmmm. Please don't die. GameMonetize 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.