|
1 | 1 | <idea-plugin> |
2 | 2 | <id>com.faebeee.reactcomponentcreator</id> |
3 | 3 | <name>React Component Creator</name> |
4 | | - <version>0.3.1</version> |
| 4 | + <version>0.4.0</version> |
5 | 5 | < vendor email= "[email protected]" url= "http://fabs.io">Fabio Gianini</ vendor> |
6 | 6 |
|
7 | 7 | <!-- please see http://www.jetbrains.org/intellij/sdk/docs/basics/getting_started/build_number_ranges.html for description --> |
|
17 | 17 | <ul> |
18 | 18 | <li>An Brainstorm Plugin to create a new react functional component with all additional files like |
19 | 19 | SCSS, Spec, Storybook.</li> |
20 | | - <li>Add Redux reducer module with actions, mutations, state and types</li> |
| 20 | + <li>Add Redux reducer module with actions, mutations, state and types.</li> |
| 21 | + <li>Add custom templates to match your coding style and your needs.</li> |
21 | 22 | </ul> |
| 23 | + <h1><a href="#custom-templates" id="custom-templates">Custom Templates</a></h1> |
| 24 | + <p>If you are not happy with the predefined templates, you can choose your |
| 25 | + own templates. The templates will be processed with mustache as templating. |
| 26 | + All variables can also be used for the filenames.</p> |
| 27 | + <p>Following variables are available</p> |
| 28 | + <p><strong>Component</strong></p> |
| 29 | + <table> |
| 30 | + <thead> |
| 31 | + <tr><th> variable </th><th> Description </th></tr> |
| 32 | + </thead> |
| 33 | + <tbody> |
| 34 | + <tr><td> {{componentName}} </td><td> the inputted component name. Without any alterations </td></tr> |
| 35 | + <tr><td> {{componentCamelcaseName}} </td><td> Camelcased input <code>my-component</code> becomes <code>MyComponent</code> </td></tr> |
| 36 | + </tbody> |
| 37 | + </table> |
| 38 | + <p><strong>Reducer</strong></p> |
| 39 | + <table> |
| 40 | + <thead> |
| 41 | + <tr><th> variable </th><th> Description </th></tr> |
| 42 | + </thead> |
| 43 | + <tbody> |
| 44 | + <tr><td> {{actionFunctionName}} </td><td> Name of the function inside the <code>actions.ts</code> file </td></tr> |
| 45 | + <tr><td> {{moduleName}} </td><td> Name of the folder </td></tr> |
| 46 | + <tr><td> {{mutationType}} </td><td> String which will be used as type of the dispatch/mutation </td></tr> |
| 47 | + <tr><td> {{moduleNamePascalCase}} </td><td> Pascalcased moduleName </td></tr> |
| 48 | + <tr><td> {{stateName}} </td><td> Name for the state. <code>my-component</code> becomes <code>MyComponentState</code> </td></tr> |
| 49 | + <tr><td> {{actionTypeName}} </td><td> Takes the input of <code>actionFunctionName</code> and capitalizes the first letter and appends <code>Action</code>. From <code>setData</code> becomes <code>SetDataAction</code> </td></tr> |
| 50 | + <tr><td> {{actionTypesEnumName}} </td><td> Name used for the action types enum. actionTypesEnumName is the namespace where all <code>mutationType</code> actions are kept </td></tr> |
| 51 | + </tbody> |
| 52 | + </table> |
22 | 53 | ]]> |
23 | 54 | </description> |
24 | 55 |
|
25 | 56 | <change-notes> |
26 | 57 | <![CDATA[ |
27 | 58 | <ul> |
28 | | - <li>v0.3.1 Export enum for action types</li> |
29 | | - <li>v0.3.0 Add <code>Add Redux Reducer</code> Action</li> |
30 | | - <li>v0.2.0 Update UI & improve code</li> |
| 59 | + <li>v0.4.0 Add Customisable templates. Improve a lot of code. Update doc</li> |
| 60 | + <li>v0.2.1 Export enum for action types</li> |
| 61 | + <li>v0.2.1 Export enum for action types</li> |
| 62 | + <li>v0.2.0 Add <code>Add Redux Reducer</code> Action</li> |
31 | 63 | <li>v0.1.0 Add <code>Add React Component</code> Action</li> |
32 | 64 | </ul> |
33 | 65 | ]]> |
34 | 66 | </change-notes> |
35 | 67 |
|
36 | 68 |
|
37 | 69 | <extensions defaultExtensionNs="com.intellij"> |
38 | | - <!-- Add your extensions here --> |
| 70 | + <projectConfigurable |
| 71 | + instance="fabs.component.settings.ComponentSettings" |
| 72 | + id="rcc.settings" |
| 73 | + displayName="React Component Creator" |
| 74 | + nonDefaultProject="true"/> |
| 75 | + |
| 76 | + <projectConfigurable |
| 77 | + instance="fabs.reducer.settings.ReducerSettings" |
| 78 | + id="rcc.settings.redux" |
| 79 | + displayName="Redux" |
| 80 | + parentId="rcc.settings" |
| 81 | + nonDefaultProject="true"/> |
| 82 | + |
| 83 | + <projectConfigurable |
| 84 | + instance="fabs.component.settings.ComponentSettings" |
| 85 | + id="rcc.settings.component" |
| 86 | + displayName="Component" |
| 87 | + parentId="rcc.settings" |
| 88 | + nonDefaultProject="true"/> |
| 89 | + |
| 90 | + <projectService serviceInterface="fabs.reducer.data.ReducerSettingsState" |
| 91 | + serviceImplementation="fabs.reducer.data.ReducerSettingsState"/> |
| 92 | + |
| 93 | + <projectService serviceInterface="fabs.component.data.ComponentSettingsState" |
| 94 | + serviceImplementation="fabs.component.data.ComponentSettingsState"/> |
39 | 95 | </extensions> |
40 | 96 |
|
41 | 97 | <actions> |
42 | 98 | <group description="React" id="React"> |
43 | 99 | <separator/> |
44 | 100 | <action id="ReactComponent.ComponentCreatorAction" |
45 | | - class="fabs.component.ComponentCreatorAction" |
| 101 | + class="fabs.component.action.ComponentCreatorAction" |
46 | 102 | icon="/icons/component.png" |
47 | 103 | text="React component" |
48 | 104 | description="create new react component"> |
49 | 105 | </action> |
50 | 106 |
|
51 | 107 | <action id="ReactComponent.ReducerCreatorAction" |
52 | | - class="fabs.reducer.ReducerCreatorAction" |
| 108 | + class="fabs.reducer.action.ReducerCreatorAction" |
53 | 109 | icon="/icons/store.png" |
54 | 110 | text="Redux reducer" |
55 | 111 | description="create new redux reducer"> |
|
0 commit comments