Skip to content

Commit da90058

Browse files
Merge pull request #560 from Gillespie59/development
4.0.0
2 parents 9d64ca1 + 3d641b0 commit da90058

18 files changed

+741
-469
lines changed

.travis.yml

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,6 @@
11
language: node_js
22
node_js:
3-
- 9
4-
- 8
5-
- 7
6-
- 6
3+
- 10
4+
- 9
5+
- 8
76
after_script: "cat ./coverage/lcov.info | ./node_modules/coveralls/bin/coveralls.js"

docs/rules/file-name.md

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,7 @@ All your file names should match the angular component name.
66
The second parameter can be a config object [2, {nameStyle: 'dash', typeSeparator: 'dot', ignoreTypeSuffix: true, ignorePrefix: 'ui'}] to match 'avenger-profile.directive.js' or 'avanger-api.service.js'.
77
Possible values for 'typeSeparator' and 'nameStyle' are 'dot', 'dash' and 'underscore'.
88
The options 'ignoreTypeSuffix' ignores camel cased suffixes like 'someController' or 'myService' and 'ignorePrefix' ignores namespace prefixes like 'ui'.
9+
It's possible to specify a regexp for ignorePrefix. Example RegExp: "/^ui./".
910

1011
The naming scheme is <componentName><typeSeparator><componentType>.js
1112

@@ -130,6 +131,13 @@ The following patterns are **not** considered problems when configured `{"typeSe
130131
// valid with filename: src/app/utils.module.js
131132
angular.module('ui.utils', function(){});
132133

134+
The following patterns are **not** considered problems when configured `{"typeSeparator":"dot","ignorePrefix":"/^ui./"}`:
135+
136+
/*eslint angular/file-name: [2,{"typeSeparator":"dot","ignorePrefix":"/^ui./"}]*/
137+
138+
// valid with filename: src/app/utils.module.js
139+
angular.module('ui.utils', function(){});
140+
133141
The following patterns are considered problems when configured `{"typeSeparator":"dot","componentTypeMappings":{"factory":"factory","provider":"provider"}}`:
134142

135143
/*eslint angular/file-name: [2,{"typeSeparator":"dot","componentTypeMappings":{"factory":"factory","provider":"provider"}}]*/

examples/file-name.js

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -60,6 +60,9 @@ angular.factory('ui.UserUtils', uiUserUtils);
6060
// example - valid: true, options: [{"typeSeparator":"dot", "ignorePrefix": "ui."}], filename: "src/app/utils.module.js"
6161
angular.module('ui.utils', function(){});
6262

63+
// example - valid: true, options: [{"typeSeparator":"dot", "ignorePrefix": "/^ui./"}], filename: "src/app/utils.module.js"
64+
angular.module('ui.utils', function(){});
65+
6366

6467
// example - valid: true, options: [{"typeSeparator":"dot", "componentTypeMappings": {"factory": "factory", "provider": "provider"}}], filename: "src/app/users.factory.js"
6568
angular.factory('users', function(){});

0 commit comments

Comments
 (0)