For an angular 1.x project that uses typescript, what are the Pros and Cons of using AMD?
Meaning, running tsc
with the params -m amd
and using requirejs, versus simply using the /// <reference path="..." />
for internal modules as well and wrapping in module
(s).
Which-
- Makes more sense for angularjs? (if you think one is better than the other in this particular case).
- Is better for large scale angular apps?
- Would be better at minification+obfuscation of large code base?
Angular1 :
--module amd
Angular2 :--module system
as that is what the angularjs team uses internally.Yes.
--out
andreference
comments are a bad idea. More : https://github.com/TypeStrong/atom-typescript/blob/master/docs/out.mdIt would be the same. The main advantage is dev time readability and maintainability.