I would to understand the use of angular module more clearly and deeply. I have a folder of directives where each directive is on separate file.
My first file(first directive) has a declaration of
angular.module("Name",["Dep1","Dep2"]).directive(....)
My second file has a declaration of
angular.module("Name").directive(.....)
My third file has a declaration of
angular.module("Name").directive(.....)
and so on.
There for my references of files is like this.
<script src="FirstFile"></script>
<script src="SecondFile"></script>
<script src="ThirdFile"></script>
I have a couple of questions:
1.How can I get rid of angular.module("Name") declaration in every file?
- why my first declaration have to be angular.module("Name",["Dep1","Dep2"]) with list of dependencies, can I call this file second in row?