跳到主要内容

import-notation

Specify string or URL notation for @import rules.

@import url("x.jpg");
/** ↑
* This notation */

The fix option can automatically fix all of the problems reported by this rule.

Options

string: "string"|"url"

"string"

@import rules must always use string notation.

The following patterns are considered problems:

@import url(foo.css);
@import url('foo.css');
@import url("foo.css");

The following patterns are not considered problems:

@import 'foo.css';
@import "foo.css";

"url"

@import rules must always use URL notation.

The following patterns are considered problems:

@import 'foo.css';
@import "foo.css";

The following patterns are not considered problems:

@import url(foo.css);
@import url('foo.css');
@import url("foo.css");