1, to Hacks said no
Hacks is designed to allow CSS encoding to maintain the normal display of the site in different browsers and platforms. Although hacks has become an acceptable practice in the community, this does not mean that "CSS hacking" is a principle you should follow. The problem with this design approach is that it means you're getting the standard CSS more complex to solve the problem. Although you may think that one or two hacks will not hurt anyone, this kind of thinking can have a negative impact on your overall design ideas.
2, Documents
Whether your project is a single person or a team player, it is important that you work on the file creation. If you are a single project on the team, there is always a chance that your single project will eventually evolve into a team project, and if this happens, there will be a lot of files on hand to create good file classification and name, write notes, collaborate more easily.
The annotation file that involves creating CSS code, most designers naturally put it into the code that directly relates to them/* and */. Technically, there is nothing wrong with this approach. However, commenting directly into your CSS code will increase the size of the file, thereby increasing the load time and slowing the overall performance of a site. If you want to be a top-tier CSS code writer, you should write the annotations in a separate file.
3. Never stop Learning
You may think that this last principle sounds cliché, but it is also the most important of the 8 articles. If you are committed to being the best designer, you need to make sure that you have been working to broaden your CSS knowledge. Luckily, if you want, it's easy to do and continue with your CSS education. Just type "CSS" to Google and you'll see 483 million results for you to browse.
4, the authentication of the consortium
If you are 1 people who are writing CSS encodings, it is recommended that you validate the CSS code you create each time. But there are a lot of designers who are skipping this important step. Verify any problems with your code cleanup feedback and make sure it works for visitors friendly. In addition to validating your CSS files, you should also validate your HTML or XHTML files. Before validating these files, make sure that you have declared the correct HTML or XHTML doctype. Stating that your DOCTYPE seems to be a simple detail, but many designers after many times to verify that the original is because he did not declare doctype.
5. Class Name
If you ask a new designer, they decide how to name class, they might say, it's not important. While there are no strict requirements for the naming of CSS classes Technically, we must correct those mistakes. Suppose you want to create a class to control a section on a Web page.
6, do not abuse div
Because Div provides a high degree of flexibility, it's easy for new people to overuse them. To avoid overly using div tags, you should always ask yourself whether you have an actual HTML tag when writing HTML code. Once you start thinking about the div problem, you'll soon be using the appropriate HTML tags instead of automatically creating a new div. Not only can it reduce the amount of code, but it will also give your code a more reasonable load time.
7, do not forget the printer
As an excellent designer, you should be more inclined to love technology, because you are a minority part of life and breathing in technology. However, since people still need to print out information from the Internet, you should consider making CSS content friendly to printers. Your peers appreciate the sites you create, perhaps they are interested to know your layout, perhaps they intend to print your CSS for reference, so as a good designer please do not ignore the printer.
8, the use of shorthand
Once you get used to shorthand, it's also one of the most effective ways you can become a good designer. Use a variety of shorthand methods to minimize your files, while also reducing the load time of the site. In addition, it not only makes it easier to organize your code, but also makes it easier to modify the code in the future.