build: initial configuration of Tailwind CSS

This commit is contained in:
Oliver Davies 2023-01-01 20:27:18 +00:00
parent 613c6b1e0e
commit 87c694eec3
4 changed files with 24 additions and 2 deletions

1
fractal/.gitignore vendored
View file

@ -1 +1,2 @@
/node_modules/
/public/build/

View file

@ -1,6 +1,6 @@
/** @type {import('tailwindcss').Config} */
module.exports = {
content: [],
content: ["./src/**/*.njk"],
theme: {
extend: {},
},

View file

@ -1,7 +1,8 @@
'use strict';
const fractal = module.exports = require('@frctl/fractal').create();
const mandelbrot = require("@frctl/mandelbrot")
const mandelbrot = require("@frctl/mandelbrot");
const path = require("path");
fractal.set('project.title', 'oliverdavies.uk');
@ -9,8 +10,11 @@ fractal.components.set('path', __dirname + '/src/components');
fractal.components.engine(require('@frctl/nunjucks'));
fractal.components.set('ext', '.njk');
fractal.docs.set('path', __dirname + '/src/docs');
fractal.web.set('static.path', path.join(__dirname, 'public'));
fractal.web.theme(
mandelbrot({
information: [

View file

@ -0,0 +1,17 @@
<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1">
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<title>{{ _target.title }} &middot; {{ _config.project.title }}</title>
<link rel="stylesheet" href="{{ '/build/tailwind.css' | path }}">
</head>
<body class="bg-gray-100">
{{ yield | safe }}
</body>
</html>