Ranter
Join devRant
Do all the things like
++ or -- rants, post your own rants, comment on others' rants and build your customized dev avatar
Sign Up
Pipeless API
From the creators of devRant, Pipeless lets you power real-time personalized recommendations and activity feeds using a simple API
Learn More
Comments
-
@searchindex
1.The file structure is weird.am still confused about what goes where.
2.typescript really urks me -
Anyways I'm still in my Infancy Days of learning angular 2.I should get used to this stuff.but I'm still going to rant on about why the guys developing angular itself didn't make a features upgrade to angular 1.x and instead went with creating an entirely different framework.
-
Are you using angular CLI? If not, give it a try, it puts everything (except for services) where it should be automatically.
Other than that, keep at it; it's definitely weird coming from ng1 but once you get the hang of it ng1 will seem clumsy by comparison. -
@zmzmuazzam98
I agree, Angular2 should have been named something else. But is what it is.
Is weird in the beginning but it all makes sense.
My advise is start with the cli and with visual studio code with language service addon installed.
That will help a lot and unleash the power of typescript -
@DevotedSniper
*ngIf='showFlag' on the div
And then in the component change showFlag variable to true/false will make the trick. -
@DevotedSniper
For that spinner i've done something similar. I did a component that i had to app.component (right after router-outlet) so it shows in every page. Let's call this spinner. The spinner subscribes (rxjs) to a service (lets call it busyservice). This service emits if the app is busy or not and then shows the spinner. Any angular element can inject busyService and say if the app is busy or not. I even did an override on the http service to block the app on every ajax call.
How about this solution?
Related Rants
I'm really struggling with angular 2 .Any tips?
undefined
#javascriptframworksgonewrong
angular2