@putout/plugin-printer 7.1.0 → 7.1.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.
- package/README.md +2 -0
- package/lib/apply-create-test-url/index.js +2 -2
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -114,6 +114,7 @@ Checkout in 🐊[**Putout Editor**](https://putout.cloudcmd.io/#/gist/ddf1425ace
|
|
|
114
114
|
|
|
115
115
|
```js
|
|
116
116
|
import {createTest} from '#test';
|
|
117
|
+
|
|
117
118
|
const {test, fixture} = createTest(__dirname);
|
|
118
119
|
```
|
|
119
120
|
|
|
@@ -121,6 +122,7 @@ const {test, fixture} = createTest(__dirname);
|
|
|
121
122
|
|
|
122
123
|
```js
|
|
123
124
|
import {createTest} from '#test';
|
|
125
|
+
|
|
124
126
|
const {test, fixture} = createTest(import.meta.url);
|
|
125
127
|
```
|
|
126
128
|
|
|
@@ -5,9 +5,9 @@ const {isESM} = operator;
|
|
|
5
5
|
export const report = () => `Use 'import.meta.url' instead of '__dirname'`;
|
|
6
6
|
|
|
7
7
|
export const match = () => ({
|
|
8
|
-
'
|
|
8
|
+
'createTest(__dirname)': (vars, path) => isESM(path),
|
|
9
9
|
});
|
|
10
10
|
|
|
11
11
|
export const replace = () => ({
|
|
12
|
-
'
|
|
12
|
+
'createTest(__dirname)': 'createTest(import.meta.url)',
|
|
13
13
|
});
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@putout/plugin-printer",
|
|
3
|
-
"version": "7.1.
|
|
3
|
+
"version": "7.1.1",
|
|
4
4
|
"type": "module",
|
|
5
5
|
"author": "coderaiser <mnemonic.enemy@gmail.com> (https://github.com/coderaiser)",
|
|
6
6
|
"description": "🐊Putout plugin adds support of transformations for @putout/printer",
|