Skip to content

Commit

Permalink
feat: added tailwind css support
Browse files Browse the repository at this point in the history
  • Loading branch information
madkarmaa committed Feb 16, 2024
1 parent 614745d commit d3b2c68
Show file tree
Hide file tree
Showing 8 changed files with 1,188 additions and 8 deletions.
1,146 changes: 1,139 additions & 7 deletions package-lock.json

Large diffs are not rendered by default.

3 changes: 3 additions & 0 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -14,13 +14,16 @@
"@sveltejs/adapter-static": "^2.0.3",
"@sveltejs/kit": "^1.20.4",
"@types/semver": "^7.5.2",
"autoprefixer": "^10.4.17",
"eslint": "^8.28.0",
"eslint-config-prettier": "^8.5.0",
"eslint-plugin-svelte": "^2.30.0",
"postcss": "^8.4.35",
"prettier": "^2.8.0",
"prettier-plugin-svelte": "^2.10.1",
"semver": "^7.5.4",
"svelte": "^4.0.5",
"tailwindcss": "^3.4.1",
"vite": "^4.4.2"
},
"type": "module",
Expand Down
6 changes: 6 additions & 0 deletions postcss.config.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
export default {
plugins: {
tailwindcss: {},
autoprefixer: {},
},
}
9 changes: 9 additions & 0 deletions src/components/SectionWrapper.svelte
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
<script>
export let id;
</script>

<section {id}>
<div>
<slot />
</div>
</section>
17 changes: 17 additions & 0 deletions src/routes/revanced-interactive-tutorial/+page.svelte
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
<script>
// your script goes here
</script>

<div class="container bgGrid" />

<style>
.bgGrid {
background-size: 40px 40px;
background-image: linear-gradient(to right, grey 1px, transparent 1px),
linear-gradient(to bottom, grey 1px, transparent 1px);
}
.container {
flex: 1;
}
</style>
4 changes: 4 additions & 0 deletions src/routes/style.css
Original file line number Diff line number Diff line change
@@ -1,3 +1,7 @@
@tailwind base;
@tailwind components;
@tailwind utilities;

* {
box-sizing: border-box;
padding: 0;
Expand Down
3 changes: 2 additions & 1 deletion svelte.config.js
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
import adapter from '@sveltejs/adapter-static';
import { vitePreprocess } from '@sveltejs/kit/vite';
// import { vitePreprocess } from '@sveltejs/kit/vite';
import { vitePreprocess } from '@sveltejs/vite-plugin-svelte';

const dev = process.argv.includes('dev');

Expand Down
8 changes: 8 additions & 0 deletions tailwind.config.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
/** @type {import('tailwindcss').Config} */
export default {
content: ['./src/**/*.{html,js,svelte,ts}'],
theme: {
extend: {}
},
plugins: []
};

0 comments on commit d3b2c68

Please sign in to comment.