Closed vjoao closed 8 years ago
Hi @vjoao thanks for this. Definitely not desirable behavior. I will circle @NathanaelA here, any thoughts on how we could avoid this scenario with the post installer?
@vjoao interesting. I'm sure we can fix this. Can you tell me specifically which items it changed in your package.json and index.js, I thought I already had a safety check at least on the package.json...
@NathanaelA I believe what's occurring here is for his collaborator, since he was just setting things up for the first time (pulling from @vjoao's repo which had already contained the postinstall modifications), it just overwrote them since it was a first time install for his collaborator.
@vjoao did you commit the nativescript
folder to your repo? @NathanaelA We may be able to determine our '{N} is installed' check by seeing if that folder exists alone.
Yes, the nativescript folder was on source control.
@vjoao I have a fix coming this week for your reported issue. Thanks again for reporting it.
In meantime, are you using routing? via @angular/router
or @angular/router-deprecated
?
@NathanWalker cool =)
I'm not using the router yet but we would go with the new one @angular/router
Ok good to know. Thanks! I'll let you know when this issue is resolved!
Well thank you! Amazing job =)
Ok @vjoao Please update your main project package.json
as well as nativescript/package.json
to use latest version:
"nativescript-ng2-magic": "^1.5.0"
Lemme know if you have any further issues.
I'm installing the ng2-magic and it's OK. The problem is when sharing code, as we changed the main.ts file to point to our start component and changed the run tasks on package.json. When another collaborator ran npm install to get his dependencies, the hooks just overwrote my changes on main.ts and on package.json.
I guess this is not the desirable behavior.
Any thoughts?