You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: README.md
+22-6Lines changed: 22 additions & 6 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -6,21 +6,27 @@ A set of usefull snippets and commands we use at Ackee for web apps development.
6
6
7
7
## Features
8
8
9
-
* Commands for project scaffolding
9
+
* Commands for project scaffolding (typescript supported)
10
10
* React/Fela snippets
11
11
12
+
## Contents
13
+
14
+
-[Commands](#commands)
15
+
-[Settings](#settings)
16
+
-[Snippets](#snippets)
17
+
12
18
## Commands
13
19
14
20
### Create component
15
-
*`Component.jsx` - React stateless component
16
-
*`index.js` - index file to export the React component
21
+
*`Component.(j|t)sx` - React stateless component
22
+
*`index.(j|t)s` - index file to export the React component
17
23
18
24
### Create Fela component
19
25
20
26
Creates a folder with following structure:
21
-
*`Component.jsx` - React stateless component with `styles` prop
22
-
*`Component.styles.js` - fela rules
23
-
*`index.js` - index file to export the React component and wrap it with `connectFela`
27
+
*`Component.(j|t)sx` - React stateless component with `styles` prop
28
+
*`Component.styles.(j|t)s` - fela rules
29
+
*`index.(j|t)s` - index file to export the React component and wrap it with `connectFela`
24
30
25
31
#### Usage
26
32
1. Right click to a folder where you want to create a component
@@ -31,6 +37,16 @@ Creates a folder with following structure:
31
37
32
38
> **Note**: The command can also be triggered by a shortcut `cmd+a cmd+c` or by VS Code command line. But in that case the component is created in root directory of a project, because VS Code API does not provide selected folder in the explorer window. See [this issue](https://github.com/Microsoft/vscode/issues/3553) for more info.
33
39
40
+
## Settings
41
+
42
+
These settings can be changed in VS Code settings under `ackeeFrontend` namespace.
43
+
44
+
| Name | Default value | Description |
45
+
|---|---|---|
46
+
|`moduleDependencies`|`true`| If enabled it uses named imports from dependencies.js file of the module. |
47
+
|`felaHooks`|`false`| If enabled, scaffolded components will use enhanced fela hooks instead of connect HOC. |
48
+
|`typescript`|`false`| If enabled, scaffolded components will be in TypeScript. |
0 commit comments