Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/raphaeltm/pristat
Static site generator build on Prismic.io
https://github.com/raphaeltm/pristat
nodejs prismic prismicio static-site static-site-generator
Last synced: about 1 month ago
JSON representation
Static site generator build on Prismic.io
- Host: GitHub
- URL: https://github.com/raphaeltm/pristat
- Owner: raphaeltm
- License: mit
- Created: 2017-08-09T01:20:32.000Z (over 7 years ago)
- Default Branch: master
- Last Pushed: 2017-08-09T22:55:36.000Z (over 7 years ago)
- Last Synced: 2025-01-11T12:54:33.472Z (about 1 month ago)
- Topics: nodejs, prismic, prismicio, static-site, static-site-generator
- Language: JavaScript
- Size: 17.6 KB
- Stars: 1
- Watchers: 2
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: Readme.md
- License: LICENSE
Awesome Lists containing this project
README
# pristat static site generator
*This project is in its infancy. Use it at your own risk.*
---
Basically, I wanted a dead simple static site generator that played well with Prismic and didn't like the plugins for other static site generators, and found it too tedious to tie into their systems.
For many, this might not make sense, but if you just want a quick and simple way to write templates for your prismic content and generate a static site, this is for you.
---
### Structure
#### In Prismic
For your content to be rendered by pristat, it will need two fields:
```
"url" : {
"type" : "Text",
"config" : {
"label" : "URL"
}
},
"layout" : {
"type" : "Text",
"config" : {
"label" : "Layout"
}
},
```The url field determines the URL for the page (i.e. the folder in which the index.html file will be generated). Pristat only supports "pretty" urls. No filename can be specified (URLs must start and end with a /).
The layout is the filename (sans extension) for the layout you wish to use. This must be a .pug template in the _layout directory of your project.
---
### Commands
#### `pristat init`
This will prompt you for the *V2* API URL for your Prismic repository, as well as the relative path in which to build your html. Simply run it in the root directory for your project.
#### `pristat build`
This will build your static site.