Skip to content

Commit a390fa7

Browse files
author
Andrew Welch
committed
Solution refactor
1 parent 9c9400f commit a390fa7

File tree

8 files changed

+47
-48
lines changed

8 files changed

+47
-48
lines changed

src/css/app-base.pcss

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
/**
2+
* Here we add custom base styles, applied after the tailwind-base
3+
* classes
4+
*
5+
*/

src/css/app-components.pcss

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,9 @@
1+
/**
2+
* Here we add custom component classes; stuff we want loaded
3+
* *before* the utilities so that the utilities can still
4+
* override them.
5+
*
6+
*/
7+
@import './components/global.pcss';
8+
@import './components/typography.pcss';
9+
@import './components/webfonts.pcss';

src/css/app-utilities.pcss

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,11 @@
1+
/**
2+
* Include styles for individual pages
3+
*
4+
*/
5+
@import './pages/homepage.pcss';
6+
7+
/**
8+
* Include vendor css.
9+
*
10+
*/
11+
@import 'vendor.pcss';

src/css/app.pcss

Lines changed: 0 additions & 47 deletions
This file was deleted.

src/css/tailwind-base.pcss

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
/**
2+
* This injects Tailwind's base styles, which is a combination of
3+
* Normalize.css and some additional base styles.
4+
*/
5+
@tailwind base;

src/css/tailwind-components.pcss

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
/**
2+
* This injects any component classes registered by plugins.
3+
*
4+
*/
5+
@tailwind components;

src/css/tailwind-utilities.pcss

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
/**
2+
* This injects all of Tailwind's utility classes, generated based on your
3+
* config file.
4+
*
5+
*/
6+
@tailwind utilities;

src/js/app.ts

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,10 @@
11
// Import our CSS
2-
import '../css/app.pcss';
2+
import '../css/tailwind-base.pcss';
3+
import '../css/app-base.pcss';
4+
import '../css/tailwind-components.pcss';
5+
import '../css/app-components.pcss';
6+
import '../css/tailwind-utilities.pcss';
7+
import '../css/app-utilities.pcss';
38

49
import App from "../vue/App.vue";
510

0 commit comments

Comments
 (0)