File tree Expand file tree Collapse file tree 1 file changed +4
-4
lines changed Expand file tree Collapse file tree 1 file changed +4
-4
lines changed Original file line number Diff line number Diff line change @@ -96,11 +96,11 @@ module.exports = {
96
96
97
97
### ` rules[].modify `
98
98
99
- Type: ` (source: string, filename : string) => string `
99
+ Type: ` (source: string, path : string) => string `
100
100
101
101
` Required `
102
102
103
- Function accept a source and filename . Should return a modified source.
103
+ Function accept a source and file path . Should return a modified source.
104
104
105
105
WARNING: modify function should make syntax compatible changes, for example all unsupported syntax will break your build or create errors in runtime.
106
106
@@ -113,9 +113,9 @@ module.exports = {
113
113
rules: [
114
114
{
115
115
test: / my-file\. js$ / ,
116
- modify : (src , filename ) =>
116
+ modify : (src , path ) =>
117
117
src +
118
- ` \n\n // This file (${ filename } ) is written by me. All rights reserved`
118
+ ` \n\n // This file (${ path } ) is written by me. All rights reserved`
119
119
}
120
120
]
121
121
})
You can’t perform that action at this time.
0 commit comments