ember-codemod-remove-inject-as-service 1.0.0 → 1.0.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (2) hide show
  1. package/README.md +5 -5
  2. package/package.json +1 -1
package/README.md CHANGED
@@ -12,7 +12,7 @@ _Codemod to remove `inject as service`_<sup>1</sup>
12
12
  1. [Contributing](#contributing)
13
13
  1. [License](#license)
14
14
 
15
- <sup>1. `@ember/service` has provided `service` since [Ember 4.1](https://blog.emberjs.com/ember-4-1-released/). `inject`, which became an alias to `service`, is [planned to be deprecated in v6](https://rfcs.emberjs.com/id/1001-deprecate-named-inject).</sup>
15
+ <sup>1. `@ember/service` provides `service` since [Ember 4.1](https://blog.emberjs.com/ember-4-1-released/). `inject`, which became an alias to `service`, is [planned to be deprecated in v6](https://rfcs.emberjs.com/id/1001-deprecate-named-inject).</sup>
16
16
 
17
17
 
18
18
  ## Features
@@ -41,14 +41,14 @@ npx ember-codemod-remove-inject-as-service <arguments>
41
41
 
42
42
  Step 2. Fix formatting issues.
43
43
 
44
- - Optional: Do a find-and-replace-all, if you want to place `@service()` and `declare` on the same line when possible.
44
+ - Optional: Do a find-and-replace-all in TS files, if you want to place `@service()` and `declare` on the same line when possible.
45
45
 
46
- - Find: `@service\((.+)\)(\n|\s)+declare`
46
+ - Find: `@service\((.+)\)[\n\s]+declare`
47
47
  - Replace: `@service($1) declare`
48
48
 
49
- - Optional: Do a find-and-replace-all, if you want to place `@service` and `declare` on the same line when possible.
49
+ - Optional: Do a find-and-replace-all in TS files, if you want to place `@service` and `declare` on the same line when possible.
50
50
 
51
- - Find: `@service(\n|\s)+declare`
51
+ - Find: `@service[\n\s]+declare`
52
52
  - Replace: `@service declare`
53
53
 
54
54
  - Run `lint:js:fix` (i.e. autofix from `eslint` and `prettier`).
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "ember-codemod-remove-inject-as-service",
3
- "version": "1.0.0",
3
+ "version": "1.0.1",
4
4
  "description": "Codemod to remove `inject as service`",
5
5
  "keywords": [
6
6
  "codemod",