Is using CSS CSS styles a waste of time?

I'm new to Flex and wondering if other developers are using their style sheet features? The reason I ask is because for my inexperienced eye this seems like a waste of time.

What Flex calls CSS explicitly wrong is some other beast in general with css as syntax. Since many dimension properties cannot be set in the stylesheet, the main reason for using CSS is that there is no separation of content from the presentation. This is compounded by many other missing features.

It made me think it was probably a much more sensible step to just keep my entire style declaration right there in mxml, just to have it all in one place.

Is this the best way or am I missing something at all?

+3
source share
3 answers

In Flex, styles are used to define the style properties of objects. If you want to write a component where the layout and positions were defined by styles, you could. On the other hand, if you want to completely abandon the use of CSS and styles, you can also write a component that did this (although hardly without using x.setStyle (...) calls for library components).

Saying this, they are as useful as you want to create them. I can give some examples when they will be useful:

  • . (, ..) , , , . , , ?

  • . , 5 10 "setStyle" AS3 , mxml , "stylename" , css,

, , , . , Flex, ..

, CSS ( ), . , . c'est la vie. , .

+2

, , - . CSS , . , , .

+1

You can also check this . This is about the next version of flex, but it has many improvements in the workflow of the designer / developer.

0
source

Source: https://habr.com/ru/post/1721260/


All Articles