fix #32: remove rest css modules
All checks were successful
/ depoly (push) Successful in 1m28s
All checks were successful
/ depoly (push) Successful in 1m28s
This commit is contained in:
parent
8854a3b86a
commit
4718239723
23 changed files with 189 additions and 167 deletions
|
@ -99,10 +99,22 @@ by the component file, so the side effect will be applied by the bundler.
|
|||
|
||||
The speicifc component uses a root class to scope the rulesets' scope. This convention allows the component's style can be influenced
|
||||
by the other stylesheets. It works because Tutu is an end-user application, we gain the control of all stylesheets in the app (kind of).
|
||||
Keep in mind that the native stylesheets will be applied globally at any time, you must carefully craft the stylesheet to avoid leaking
|
||||
of style.
|
||||
|
||||
Styled component is still existing for its own good: decalrable and scoped by randomized names.
|
||||
Though styled component, using attributes for scoping, may not be as performant as the techniques with CSS class names;
|
||||
It's still provided in the Tutu's code infrastructure for its ease (it even provides a bridge to use js variable in css!).
|
||||
Three additional CSS layers are declared as:
|
||||
|
||||
- compat: Compatibility rules, like normalize.css
|
||||
- theme: The theme rules
|
||||
- material: The internal material styles
|
||||
|
||||
When working on the material package, if the style is intended to work with the user styles,
|
||||
it must be declared under the material layer. Otherwise the unlayer, which has the
|
||||
highest priority in the author's, can be used.
|
||||
|
||||
Styled component is still existing. Though styled component, using attributes for scoping,
|
||||
may not be as performant as the techniques with CSS class names;
|
||||
it's still provided in the code infrastructure for its ease.
|
||||
|
||||
The following is an example of the recommended usage of solid-styled:
|
||||
|
||||
|
@ -123,7 +135,7 @@ const Component = () => {
|
|||
};
|
||||
```
|
||||
|
||||
Native CSS is always recommended. When developing new component, you can use styled component first, and migrate
|
||||
When developing new component, you can use styled component at first, and migrate
|
||||
to native css slowly.
|
||||
|
||||
Before v2.0.0, there are CSS modules in use, but they are removed:
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue