Skip to content

Commit b7981f3

Browse files
committed
update readme
1 parent 7514935 commit b7981f3

File tree

1 file changed

+9
-5
lines changed

1 file changed

+9
-5
lines changed

README.md

Lines changed: 9 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -42,7 +42,7 @@ generateTemplateFiles([
4242
entry: {
4343
folderPath: './tools/templates/react/redux-store/',
4444
},
45-
stringReplacers: ['__store__', '__model__'],
45+
stringReplacers: ['__store__', {question: 'Insert model name', slot: '__model__'}],
4646
output: {
4747
path: './src/stores/__store__(lowerCase)',
4848
pathAndFileNameDefaultCase: '(kebabCase)',
@@ -107,7 +107,7 @@ The `generateTemplateFiles` function takes an array of `IConfigItem` items.
107107
entry: {
108108
folderPath: './tools/templates/react/redux-store/',
109109
},
110-
stringReplacers: ['__store__', '__model__'],
110+
stringReplacers: ['__store__', { question: 'Insert model name', slot: '__model__' }],
111111
dynamicReplacers: [
112112
{slot:'__version__', slotValue: config.version},
113113
{slot:'__description__', slotValue: config.description}
@@ -159,11 +159,15 @@ Below is an example of what you receive from the `onComplete` callback. It has t
159159
}
160160
```
161161

162-
### Replacer Slots
162+
### Replacer Slots or IReplacerSlotQuestion
163+
164+
[Replacer Slots](#replacer-slots) are unique string value(s) to be replaced by the generator. An array of string values and/or `IReplacerSlotQuestion` objects can be used.
163165

164-
[Replacer Slots](#replacer-slots) are unique string value(s) to be replaced by the generator.
166+
```javascript
167+
stringReplacers: ['__store__', {question: 'Insert model name', slot: '__model__'}];
168+
```
165169

166-
For example you can use something like this in your template files and/or in the file path names.
170+
Replacer slot can be any string value you want to use. You can use something like this in your template files and/or in the file path names.
167171

168172
- `~replacerSlot~`
169173
- `{{something else}}`

0 commit comments

Comments
 (0)