Use ESM format for JS files. Use .css extension for style sheets file

This commit is contained in:
DanikVitek
2025-05-02 14:09:44 +03:00
parent 47aa11e090
commit f0af03edb4
7 changed files with 26 additions and 29 deletions
+2 -2
View File
@@ -13,6 +13,6 @@
} }
} }
], ],
"tailwindStylesheet": "./src/app.pcss", "tailwindStylesheet": "./src/app.css",
"tailwindConfig": "./tailwind.config.cjs" "tailwindConfig": "./tailwind.config.js"
} }
@@ -1,13 +1,12 @@
const tailwindcss = require("tailwindcss"); import tailwindcss from "tailwindcss";
const autoprefixer = require("autoprefixer"); import autoprefixer from "autoprefixer";
const config = { /** @type {import('postcss-load-config').Config} */
export default {
plugins: [ plugins: [
//Some plugins, like tailwindcss/nesting, need to run before Tailwind, //Some plugins, like tailwindcss/nesting, need to run before Tailwind,
tailwindcss(), tailwindcss,
//But others, like autoprefixer, need to run after, //But others, like autoprefixer, need to run after,
autoprefixer, autoprefixer,
], ],
}; };
module.exports = config;
+1 -1
View File
@@ -1,5 +1,5 @@
<!doctype html> <!doctype html>
<html lang="en" data-theme="nord"> <html lang="en" data-theme="bumblebee">
<head> <head>
<meta charset="utf-8" /> <meta charset="utf-8" />
<link rel="icon" href="%sveltekit.assets%/favicon.svg" /> <link rel="icon" href="%sveltekit.assets%/favicon.svg" />
+1 -1
View File
@@ -1,5 +1,5 @@
<script> <script>
import "../app.pcss"; import "../app.css";
/** /**
* @typedef {Object} Props * @typedef {Object} Props
* @property {import('svelte').Snippet} [children] * @property {import('svelte').Snippet} [children]
-19
View File
@@ -1,19 +0,0 @@
const daisyui = require("daisyui");
const typography = require("@tailwindcss/typography");
/** @type {import('tailwindcss').Config}*/
const config = {
content: ["./src/**/*.{html,js,svelte,ts}"],
theme: {
extend: {},
},
plugins: [typography, daisyui],
daisyui: {
themes: ["bumblebee"],
},
};
module.exports = config;
+17
View File
@@ -0,0 +1,17 @@
import daisyui from "daisyui";
import typography from "@tailwindcss/typography";
/** @type {import('tailwindcss').Config} */
export default {
content: ["./src/**/*.{html,js,svelte,ts}"],
theme: {
extend: {},
},
plugins: [typography, daisyui],
daisyui: {
themes: ["bumblebee"],
},
};