Prerequisite for learning Angular [closed] - angularjs

Closed. This question is opinion-based. It is not currently accepting answers.
Want to improve this question? Update the question so it can be answered with facts and citations by editing this post.
Closed 4 years ago.
Improve this question
I need to learn Angular for working on a project.
I am a backend Java/Spring developer
I have knowledge of HTML and Javascript. I have also worked on basic Knockout.js.
What are the prerequisite for learning Angular ?

Moderate knowledge of HTML, CSS, and JavaScript.
Basic Model-View-Controller (MVC) concepts.
The Document Object Model (DOM).
JavaScript functions, events, and error handling.
HTML : Most of the templates we create in angularJS is in the form of handcrafted htmls. i.e. So you must know that what are forms in html and what are tags ng-form etc.
CSS : While hand crafting template you should require css to make more attractive UI design.
DOM : Document object model and how document is created. If you have good jquery background you can easily pick up this part.
Object Oriented JavaScript: Global name space: AngularJS heavily uses javascript name space. i.e.
Object Oriented JavaScript: Inheritance: Inheritance is very important concept in JavaScript. Inheritance is heavily used in all the frameworks in JavaScript. i.e.
var Employee = function(fname) {
this.fname =fname;
console.log("Your first name is "+fname);
}
var fistEmployee = new Employee("John");
var secondEmployee = new Employee("Jim");
fistEmployee.prototype.lastname = function(lname) {
this.lname=lname;
console.log("Your last name is "+lname);
}
So using prototype you can easily add properties on the fly.
Model View Whatever(MVW): This term is used heavily by all AngularJS developers. It is coined by Google. It is simple MVC concept.
Separation of Concern(SOC): SOC concept is heavily used in AngularJS. In angularJS all the controllers, directive, services and factories are made for SOC. It provide more lean and cleaner code. Also re usability automatically increases if you use SOC concept.
Promises : Promises are nothing but callbacks. When you call any AngularJS service it will be called asynchronously. When response is send from service callback hold the response and do the needful.
Test Driven Development : Best thing about AngularJS is you can easily write test script so that when you go home, you can easily have sound sleep.

You see this 1 hour Angular 7 tutorial video which explains everything what you need to start with Angular. If you can watch you will have a better understanding of things.
So in all you need five important pre-requisites for Angular :-
You need to know JavaScript in depth.You should have crystal clear concepts on Javascript closures , Javascript IIFE , prototyping and so on.
A good understanding of NodeJs is must and especially how to use NPM ( Node package manager).
You need to know typescript.
A good understanding of module loaders , binders , commonjs , AMD , UMD , ES5 and so on.
This point is not compulsory its optional. If you know VS code you can learn lot of internals of Angular. As every developer has his own favorite IDE and Editor this step is optional. I would still suggest do your first couple of practicals using VS code and then proceed with your favorite IDE.
Below is the road-map of the pre-requisites and how to learn Angular. You can start learning Angular pre-requisites from this Learn Angular Step by Step article which covers around 11 labs in depth.
And yes if you are preparing for Angular interview jobs you can check video 50 Angular Interview Questions with Answers.

The most prerequisite for learning latest Angularjs (version 5.x right now - https://angular.io/tutorial) is:
TYPESCRIPT AND SOME OOPS LIKE INHERITENCE!
Everyone knows that the basics of HTML/CSS/JS is the prerequisite of everything in web development.
Today, Many people are diving into learning angularjs without knowing or just a bit about typescript. This will make learning angular a hell of a trouble, so i thought to put my 2 cents here.
Also the top most selected answer does not emphasize on the importance of learning Typescript, it's weird.
Typescript is not known to many beginners in web development. Even it's declaration is confusing if you do not study it first.
So please start from here if you wanna learn AngularJS:
https://www.typescriptlang.org/docs/handbook/2/everyday-types.html

I think you should know about patterns of desing like MVC on angular. that's the common.
And how to use properly some parts of angular, i'll share you a guide that i've found of good practics coding in angular.
Hope this help you to start coding on Angular
Angular Style Guide

Related

AngularJS - how to start best in 2016? [closed]

Closed. This question is opinion-based. It is not currently accepting answers.
Want to improve this question? Update the question so it can be answered with facts and citations by editing this post.
Closed 7 years ago.
Improve this question
I just starting to learn AngularJS (Version 1.5.0) with Material Design for Angular - damn looks so freaking sweet :)
For building and deployment i use Gulp to automate my tasks.
So far so good, but while googling my way to more questions i found Frameworks like MEAN Stack, Meteor, lumX, Ionic and many many more.
Im wondering if its better to start with one of the Frameworks or if Gulp + AngularJS + Material Design for Angular is just fine.
Before i played a bit with Foundation for Apps which looks sweet too but i really like the look and feel from Material Design. Before i used Zurb Foundation for my Responsive Webdesign Projects but consider to jump to Material Design (which is based on FlexBox) even i miss support for some older browsers.
So im bit confused if im wasting time to learn Angular Version 1 now and better straight jump to Angular2 beta. My concern is that i may run in a lack of documentation and help. Also i have to learn more about ES6 (which is necessary in the next time anyway but makes it more hard to start). I guess lot of the stuff i will learn from Angular v1 i can later on use in Angular v2 anyway, or?
Another question for me as a Freelance Web Developer is if its not better to stick with Angular v1 for a while and learn more about it and later jump to Angular v2 when its out of beta. Because the goal is later to get into some projects and i can imagine that the companies stick with v1 for a while till v2 gets more stable.
For some starting projects i wanted to create a few Templates and Apps for my Wordpress Sites based on Angular with Material Design on a LAMP Enviroment. My Webspace sadly doesn't provide NOSQL databases yet so i guess i will keep coding on PHP / MySQL for a bit.
So in short, if you guys where in my place (experienced in Web Development but new to Angular) where would you start right now?
What Frameworks, Extensions and Tools do you recommend for Application Development with Angular?
From a business point of view when do you think will Angular2 be widely be used on live projects and is it better to start learning Angular v1 or go to v2?
Thanks for your replies.
Cheers bin2hex
Instead of giving a biased opinion, I'll just provide for you a few links of project structures that are being used currently that might serve you some guidance.
https://github.com/TheLarkInn/angular-starter-es6-webpack (This one is Shamelessly authored by me).
https://github.com/AngularClass/angular2-webpack-starter
https://github.com/AngularClass/NG6-starter (I took some pieces from this repo to create mine).
I'd recommend looking into writing Angular in the 'Component Style' (like the above links). It is a new way to start out using Angular 1/2 for the future and at the least you can use these repositories as thought-provoking brain-food for your own standards.
There are also other bundling platforms such as Browserify and JPSM, however Webpack provides a lot of awesome out of the box functionality that makes Angular development really awesome.
I don't know much about AngularJS V2, but I made some AngularJS V1 projects last year. Here tools I use to make my AngularsJS V1 projects:
As project generator:
Yeoman
As depedency manager (included in Yeoman angular generators):
Bower
As task runner (included in Yeoman angular generators):
Grunt
Set of prebuilt UI components based on AngularJS directives:
Angular Material
Angular Strap
Angular UI
Actually in my opinion is better use AngularJS V1 for production purpose.
The most important thing is something you haven't considered. All that matters is that you get your html/css/javascript to the browser. Everything in-between is trivial and leg work.
Now that Angular belongs to google, they have started very rapid development to support developers of all sorts. Either way it's going to be very stable, and if you keep your code modulare and clean, it's easy to transfer. I would say just make something, make what you need, and keep working on it over time and as the framework evolves, and change your code to match. If you keep waiting for the next big thing nothing will get done, so it's better to choose a framework and stick to it.
I word my answer like this because your question is very subjective, and you should experiment and find an answer based on your needs. As a web developer, you have to learn many different languages anyway, so start with where you think is best, and grow as you figure out what you need.

How is Angular JS better than Knockout JS OR Should I prefer Angular JS or Knockout JS? [closed]

Closed. This question is opinion-based. It is not currently accepting answers.
Want to improve this question? Update the question so it can be answered with facts and citations by editing this post.
Closed 7 years ago.
Improve this question
Which one is easy to use?
What are the features of preference in both?
What is the percent of usage of both?
What should we know before using both or anyone?
That is based on your need.
For data driven app. Choose Angular. With it's nice data binding
The fundamental difference between the two solutions is that AngularJS
manages the whole application and defines guidelines on how the
application code should be structured, whereas with KnockoutJS the
application structure is entirely up to you.
Knockout has a low barrier of entry, but is also harder to manage when
code base and complexity grows. It is not easy to build the necessary
infrastructure correctly, and poor decisions made in structuring code
may cost a lot to fix in the future.
Angular’s ability to bind directly to plain objects, modular
structure, and strict development guidelines prevent many issues right
from the start, and provide a strong architectural foundation for the
application.
Knockout is primarily used to control UI representation in lower
complexity applications, whereas Angular is a JavaScript framework
that is much better suited for large, complex enterprise applications.
It provides not only UI binding, but also best practices for
application structure, development and testing.
Few more added to this:
Knockout is like light weight Angular
Knockout doesn't have routing, Angular have it. But if you want to
use routing in Knockout you may use Sammy.js / A Small Web Framework
with Class / RESTFul Evented JavaScript
Knockout and Angular have automatic data binding
Knockout is popular in .net development, while Angular is backed up
by Google Angular has service, directives, Knockout doesn't have
References :
https://www.devbridge.com/articles/angular-vs-knockout-similarities-and-fundamental-differences/
https://www.codementor.io/reactjs/tutorial/reactjs-vs-angular-js-performance-comparison-knockout
Angular.js vs Knockout.js vs Backbone.js
https://www.quora.com/How-do-Angular-js-and-Knockout-compare

Ionic framework + Google material design, which framework to use? [closed]

Closed. This question is opinion-based. It is not currently accepting answers.
Want to improve this question? Update the question so it can be answered with facts and citations by editing this post.
Closed 7 years ago.
Improve this question
I really want to use Ionic Material Design into my app. I am currently using Ionic Material: http://ionicmaterial.com/
It is really easy to use and it work great sometime but not the others. It is little bit buggy on the actual devices and it is NOT PRODUCTION ready (and I am using it on a production app...)
I heard someone has success with Ionic Material - http://materializecss.com/
But is this play well with Ionic? I heard it need jQuery. Does jQuery play well with Ionic? (never combine these 2 together...since jQuery is evil and why we use Ioinc + AngularJS the first place...correct me if I am wrong of this opinion...)
And there is other option out there. And I heard a lots of painful stories Angular Material with Ionic...anyone agree?
I just want to find the best framework before I dive myself into modification. I will start a poll if I can!
I haven't used the Ionic Material tool much, but agree it is primarily a fun dev tool and not ready for production (not that it might be eventually, but its certainly not as field tested as Ionic itself).
Can Ionic and jQuery work together? Sure. Its really can Angular and jQuery work together, since Ionic leverages Angular. Its common to use jQuery with Angular (Angular itself uses a subset of jQuery already, and will use the entire jQuery version if it is found on the page.) jQuery is not evil, the prolific use of jQuery for simple things that can be done without jQuery is what people often refer to as 'evil'. Think of it like loading jQuery just to use it for 5 lines of JavaScript that could have been written without jQuery to begin with.
You can also look at Angular Material (https://material.angularjs.org) for a Google backed project that was actually built with help from the Ionic team. However, it is not Ionic and not finished either. I use it in my projects though haven't used it much on mobile yet (it is designed to meet Material Design spec, which is designed for all platforms).
Lastly, you could just use Ionic. There are some customizations you can make, and I don't know what your vision is exactly, but I think it is the most robust option for hybrid apps today.
I'm using materializecss without any problems. jQuery is mandatory but I did not have any problems with it. I also tried muicss but I had some issues on the iPhone 6 with the button animation.

Angularjs for large web application [closed]

Closed. This question needs to be more focused. It is not currently accepting answers.
Want to improve this question? Update the question so it focuses on one problem only by editing this post.
Closed 8 years ago.
Improve this question
Would angularjs be suitable to handle large scale web application? Is reliable enough for good performance at scale ?
Its depend on your requirement. As Angular is the best for CRUD application, if your application doesn't have too much complexity then you can surely go with Angular. If you required too much DOM manipulation which usually requires for gaming app then Angular can be painful.
Is Angular slow?
Well, In some cases, you may feel that angular is very slow. Specially when you iterate over the complex JSON then there may be too much data binding so angular gets slow after 2500+ watches.
There are lots of directive to overcome this problem. Also day by day Angular itself updating their library to solve these kind of problems. Some of the directives which is helpful to improve performance of Angular are as below:
Angular Once
Angular InView
Quick ng-repeat Directive (Customized ng-repeat directive)
Karl Seamon's saying about Angular Performance
Points that should be clear in mind while using Angular for Large Application
The best feature of Angular can be painful if you don't implement it in a right way. if you are new to angular and you have worked with jQuery then first of all you need to change your thinking towards problems to Angular way rather than jQuery. Read this
Angular Scope
Angular Directive
Simply, you must be clear about the basic concepts of an Angular to use it properly. Angular also gives amazing feature of unit testing. You should write tests for each smaller chunks of your code.
I'm fan of angular. It's awesome. I would surely recommend you AngularJS.
It really comes down to your definition of a large web application. As Angular is modular by design and integrates seemlessly out of the box with unit testing in that regard its great for large web applications.
Angular is a framework for building applications and once you get it more or less right your benefits pop right out at you. Try doing similar things with jQuery or even Backbone and you will have problems (jQuery might be an unfair comparison, unless we speak of the ability to organize modular code easily).
This is a great article that outlines angular in large applications.
Also from wunderkind Brian Ford this article.

Differences between Angular.js and Angular.dart? [closed]

Closed. This question needs to be more focused. It is not currently accepting answers.
Want to improve this question? Update the question so it focuses on one problem only by editing this post.
Closed 9 years ago.
Improve this question
I know a bit about Angular.js, but I want to teach myself Dart and Angular.dart now. I'm a bit curious what the differences between the two are, though. The Angular.dart tutorial specifically says it won't compare the two. Does anyone who has used both have a perspective on what the differences are?
Update #2 (Aug '16) A Dart version of Angular is now maintained by the Dart team on Github: dart/angular2 on github
Update: The AngularDart project is mothballed and has been superseded by Angular2. Angular2 is the most recent iteration of Angular and works in Dart.
The original answer below compares AngularDart and AngularJS 1.x.
AngularDart and AngularJS are both maintained by the Angular team. We've taken a lot of knowledge from the JS side and applied it to Dart. We have also taken a lot of code and ported it straight to the Dart world.
At a technical level, in the core of Angular:
The expression language is compatible between the two versions. The AngularDart parser started as a straight port from JS but has been evolving on its own. A big difference there is that the Dart parser supports multiple backends, including a Dart code generator.
The DI system is different. In Dart it is class based where in Javascript it is symbol based.
The compiler has been completely rewritten in the Dart version. This means that directives behave differently and now there is a distinction between "structural directives" which modify the DOM, "decorative directives" and components.
ng-transclude has "melted into the browser", replaced by the standard shadow DOM.
directive controllers have been merged into components
directives in AngularDart are declared with an annotated class. link / compile functions are replaced with an apply function
In AngularDart, the scope is digested automatically through Dart zones, eliminated the need from scope.$apply.
AngularDart has a concept of attribute maps which hasn't made it back to AngularJS yet. This means that directives should need many fewer scope.$watches or even a dependency on the Scope.
There may be other differences, but that is a good list to get you started.
So the first difference is pretty obvious: AngularJS is written in JavaScript whereas Angular.dart is written in dart.
While Angular.dart follows the core principles of AngularJS it seems to be a bit of a playground for new features to evolve. I guess the core team takes all the learnings from AngularJS and tries to implement things just slightly better for the Angular.dart version. Currently it seems as if a bunch of things are first implemented in the dart version of Angular before they get backported to AngularJS. For instance they just added a more lightweight version of ng-repeat which eventually should end up in AngularJS.
Also the Angular team recently shared some insights on what's planned for Angular 2.0. I bet most of those things will first land in Angular.dart before they land in AngularJS.
Update 01/2018
See also What's the difference between Angular 2 TS and Angular 2 Dart?
Update 08/2016
Angular 2 for JS and Dart are now independent projects and will diverge to some degree.
For example the NgModule introduced in TS RC.5 will probably not land in Dart and also the router module will probably not be translated directly.
These are changes that were necessary in TS for lazy loading. Dart has an easier lazy loading story and doesn't need many of the changes introduced in Angular2 for TS.
Update
With Angular 2 there are (almost) no differences anymore because Angular.dart and Angular.js are auto-generated from the same TypeScript source.
http://techcrunch.com/2015/03/05/microsoft-and-google-collaborate-on-typescript-hell-has-not-frozen-over-yet/
Original
Analog of ngTransclude in Angular.Dart
Angular.dart uses shadowDom while AngularJs doesn't.
AngularJs uses ngTransclude instead.
What is the difference between ng-app and data-ng-app?
Angular.dart seems not to support other prefixes like discussed in the linked question.
Angular.dart has no equivalent to ng-init.
(see also GitHub issue - port: ng-init)
Angular.dart has no ng-controller directive (port: ngController)
instead #NgController(selector:'[foo-controller]', publishAs:'foo') is used
Angular.dart doesn't support ng-repeat with maps (ng-repeat with a Map not working)
Angular.dart has no restrict Has Angular.dart directive an equivalent to AngularJS's `restrict`
Misko Hevery the creator of AngularJS and member of the AngularDart team answered a similar question here
This article lists several differences: ANGULARDART FOR ANGULARJS DEVELOPERS. INTRODUCTION TO THE BEST ANGULAR YET.

Resources