Skip to content

Commit f4779ee

Browse files
authored
[fix] don't emit css option deprecation warning for now (#8012)
1 parent ee480bd commit f4779ee

File tree

2 files changed

+13
-7
lines changed

2 files changed

+13
-7
lines changed

CHANGELOG.md

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,9 @@
11
# Svelte changelog
22

3+
## Unreleased
4+
5+
* Do not emit deprecation warnings for `css` compiler options for now ([#8009](https://github.com/sveltejs/svelte/issues/8009))
6+
37
## 3.53.0
48

59
* Check whether `parentNode` exists before removing child ([#6037](https://github.com/sveltejs/svelte/issues/6037))

src/compiler/compile/index.ts

Lines changed: 9 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -89,13 +89,15 @@ function validate_options(options: CompileOptions, warnings: Warning[]) {
8989

9090
if (css === true || css === false) {
9191
options.css = css === true ? 'injected' : 'external';
92-
const message = `options.css as a boolean is deprecated. Use '${options.css}' instead of ${css}.`;
93-
warnings.push({
94-
code: 'options-css-boolean-deprecated',
95-
message,
96-
filename,
97-
toString: () => message
98-
});
92+
// possibly show this warning once we decided how Svelte 4 looks like
93+
// const message = `options.css as a boolean is deprecated. Use '${options.css}' instead of ${css}.`;
94+
// warnings.push({
95+
// code: 'options-css-boolean-deprecated',
96+
// message,
97+
// filename,
98+
// toString: () => message
99+
// });
100+
// }
99101
}
100102

101103
if (namespace && valid_namespaces.indexOf(namespace) === -1) {

0 commit comments

Comments
 (0)