File tree Expand file tree Collapse file tree 1 file changed +11
-7
lines changed Expand file tree Collapse file tree 1 file changed +11
-7
lines changed Original file line number Diff line number Diff line change 1
1
### CSS constructor π for React components
2
2
3
3
![ beta] ( https://img.shields.io/badge/status-beta-yellow.svg )
4
+
4
5
--
5
6
6
7
Every React component gets a javascript constructor for functional logic.
@@ -56,21 +57,24 @@ export default class Hello extends React.Component {
56
57
57
58
#### Usage
58
59
59
- ```
60
- npm install css-constructor --save
61
- ```
60
+ 1 . ` npm install css-constructor --save `
62
61
63
- Add a ` @css ` block just before the ` render ` function (important)
62
+ 2 . Add a ` @css ` block ** just before** the ` render ` function (important)
63
+
64
+ 3 . Add ` transform-decorators-legacy ` to ` plugins ` in ` .babelrc ` (Already downloaded with π)
65
+
66
+ You can start using this right away. Even though π is in ` BETA ` , the ` @css ` block will always look the same.
64
67
65
- Bonus: It also works with the offical emoji
68
+ --
69
+
70
+ Bonus: You can also use the official emoji instead of ` @css `
66
71
``` js
67
72
@π`
68
73
color: #FF6962;
69
74
`
70
75
```
71
76
72
- You can start using this right away. Even though π is in ` BETA ` , the ` @css ` block will always look the same.
73
-
77
+ --
74
78
75
79
#### How does it work?
76
80
You canβt perform that action at this time.
0 commit comments