
Inline adoc files when they are included exactly once. Also fix language tags because this inlining gives us better information on what language the code is written in.
42 lines
702 B
Plaintext
42 lines
702 B
Plaintext
== Why is this an issue?
|
|
|
|
The goal of this rule is to ban the usage of HTML "style" property to make sure that all CSS styles are defined in CSS classes. Consolidating all styling into classes makes it easier to read, understand and maintain.
|
|
|
|
|
|
=== Noncompliant code example
|
|
|
|
[source,html]
|
|
----
|
|
<body>
|
|
<h1 style="color: blue;">Hello World!</h1> <!-- Noncompliant -->
|
|
----
|
|
|
|
|
|
=== Compliant solution
|
|
|
|
[source,html]
|
|
----
|
|
<head>
|
|
<style>
|
|
h1 {
|
|
color: blue;
|
|
}
|
|
</style>
|
|
</head>
|
|
<body>
|
|
<h1>Hello World!</h1>
|
|
----
|
|
|
|
ifdef::env-github,rspecator-view[]
|
|
|
|
'''
|
|
== Implementation Specification
|
|
(visible only on this page)
|
|
|
|
=== Message
|
|
|
|
Use CSS classes instead.
|
|
|
|
|
|
endif::env-github,rspecator-view[]
|