dranophoenix / eleventy-pg

ELEVENTY example with pg

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool


# ELEVENTY with PG no graphql yet

initial eleventy


https://www.11ty.dev/

npm init -y
npm install --save-dev @11ty/eleventy

*to run this project. dont forget "npm install"

This will compile any content templates in the current directory or subdirectories into the output folder (defaults to _site).
npx @11ty/eleventy

Use --serve to start up a hot-reloading local web server
npx @11ty/eleventy --serve

[Browsersync] Access URLs:
-------------------------------------
Local: http://localhost:8080
External: http://192.168.1.44:8080
-------------------------------------
UI: http://localhost:3002
UI External: http://localhost:3002
------------------------------------- [Browsersync] Serving files from: _site

https://node-postgres.com/

on html file: to get a data from db use FILENAME to call this function inside
There is a hierachy of data that will be used. For more information "Data Cascade"..
eg. front matter data will be the first priority.

https://www.11ty.dev/docs/pagination/
pagination for generating every content from content list

if .eleventy.js is an ugly file name. you can specify by your self then run with --config=my-new-eleventy-config.js

About

ELEVENTY example with pg


Languages

Language:JavaScript 65.3%Language:HTML 34.7%