tailwind and incredibly basic styling proof, css, consume dist directory
This commit is contained in:
parent
12cecf4a94
commit
169e2a4ca5
11 changed files with 1837 additions and 7 deletions
|
@ -17,6 +17,13 @@ npm start
|
|||
[http://localhost:3000/](http://localhost:3000/)
|
||||
[http://localhost:3000/she/her/her/hers/herself](http://localhost:3000/she/her/her/hers/herself)
|
||||
|
||||
### Deploy
|
||||
|
||||
```bash
|
||||
npm build:css
|
||||
npm start
|
||||
```
|
||||
|
||||
### Testing
|
||||
|
||||
TODO
|
||||
|
|
4
app.js
4
app.js
|
@ -5,7 +5,9 @@ const app = express()
|
|||
|
||||
app.engine('handlebars', engine())
|
||||
app.set('view engine', 'handlebars')
|
||||
app.set('views', './views')
|
||||
app.set('views', './src/views')
|
||||
|
||||
app.use(express.static('dist'))
|
||||
|
||||
app.get('/', (req, res) => {
|
||||
res.render('home')
|
||||
|
|
1802
package-lock.json
generated
1802
package-lock.json
generated
File diff suppressed because it is too large
Load diff
|
@ -4,7 +4,10 @@
|
|||
"description": "Rawr, if you must refer to me this is how you may",
|
||||
"main": "app.js",
|
||||
"scripts": {
|
||||
"start": "node app.js",
|
||||
"start": "concurrently npm:serve:*",
|
||||
"serve:handlebars": "node app.js",
|
||||
"serve:css": "tailwindcss -i ./src/app.css -o ./dist/app.css --watch",
|
||||
"build:css": "tailwindcss -i ./src/app.css -o ./dist/app.css",
|
||||
"test": "ava"
|
||||
},
|
||||
"repository": {
|
||||
|
@ -19,7 +22,9 @@
|
|||
"homepage": "https://gitlab.com/gaiety/pronoun-monster#readme",
|
||||
"type": "module",
|
||||
"devDependencies": {
|
||||
"concurrently": "^7.6.0",
|
||||
"express": "^4.18.2",
|
||||
"express-handlebars": "^7.0.2"
|
||||
"express-handlebars": "^7.0.2",
|
||||
"tailwindcss": "^3.2.7"
|
||||
}
|
||||
}
|
||||
|
|
3
src/app.css
Normal file
3
src/app.css
Normal file
|
@ -0,0 +1,3 @@
|
|||
@tailwind base;
|
||||
@tailwind components;
|
||||
@tailwind utilities;
|
4
src/views/home.handlebars
Normal file
4
src/views/home.handlebars
Normal file
|
@ -0,0 +1,4 @@
|
|||
<div class="container mx-auto my-8">
|
||||
<h1 class="text-3xl">This is going to be such a cool site!</h1>
|
||||
<p>Check the readme!</p>
|
||||
</div>
|
4
src/views/individual.handlebars
Normal file
4
src/views/individual.handlebars
Normal file
|
@ -0,0 +1,4 @@
|
|||
<div class="container mx-auto my-8">
|
||||
<h1 class="text-3xl">Individual</h1>
|
||||
{{nominative}}/{{accusative}}/{{pronominalPossessive}}/{{predicativePossessive}}/{{reflexive}}
|
||||
</div>
|
|
@ -3,6 +3,7 @@
|
|||
<head>
|
||||
<meta charset="utf-8">
|
||||
<title>Example App</title>
|
||||
<link rel="stylesheet" href="/app.css">
|
||||
</head>
|
||||
<body>
|
||||
{{{body}}}
|
7
tailwind.config.cjs
Normal file
7
tailwind.config.cjs
Normal file
|
@ -0,0 +1,7 @@
|
|||
module.exports = {
|
||||
content: ['./src/views/**/*.{handlebars,hbs,html,htm,js}'],
|
||||
theme: {
|
||||
extend: {},
|
||||
},
|
||||
plugins: [],
|
||||
}
|
|
@ -1 +0,0 @@
|
|||
<h1>Example App: Home</h1>
|
|
@ -1,2 +0,0 @@
|
|||
<h1>Individual</h1>
|
||||
{{nominative}}/{{accusative}}/{{pronominalPossessive}}/{{predicativePossessive}}/{{reflexive}}
|
Loading…
Add table
Reference in a new issue