Changelog
Find here all changes tracked while developing picossg.
(Maybe) Future Version
High Prio
- [ ] build the docs kit so when passing no data it guides one to create a complete docs site
Eventually
- [ ] only allow-list files to be copied, not just copy all
- [ ] ignore .DS_Store files (or turn it around and allow only certain files)
- [ ] add sizes to the _file and _output, maybe also the time it took to process
- [ ] docs: make the docs correct and as I like them to be
- [ ] docs: add to the docs how to use PicoSSG when running
npm installin a project - [ ] docs: document the second parameter to the
preprocessandpostprocessfunctions - [ ] provide a playground to see play with the converter online
- [ ] plugins: a link checker would be nice
- [ ] plugins: render social-exported.json (e.g. tweets.json) to HTML, so it can be used in the site
- [ ] plugins: a
{% toc %}for md pages would be cool to render the table of contents - [ ] add the copied files to the stats, so they can be used in the templates, #niceToHave
- [ ] idea: make plugins including as easy as
plugin.<plugin-name>.preprocess(files, config) - [ ] create nicer API interface, maybe: preCreateProcessors(), preWalkFiles(), preProcess(), preOutput(), postOutput(), ...
- [ ] provide fullwidth option, see https://github.com/orgs/GitbookIO/discussions/450
- [ ] docskit: render multiple code blocks directly following one another as tabs (or introduce a
{% tabs %}tag?) - [ ] docskit: add "✨ AI Summary" tab at the top of each page, which shows the AI-generated summary of the page, we do AI-summary once, so people don't need to waste the same amount of CO2 again
- [ ] introducing "kits", ready-made page site kits, just throw md files in there and out comes e.g. a docs page
- [ ] test the error message for nunjucks parsing errors
- [ ] add a types.d.ts (maybe refactor to classes first, so extending is as easy as
class MySSG extends PicoSSG)
v6.0.1 (in the works)
- [x] the package moved to a new name:
@pic0/ssg(v6.0.0 is already available there) - [ ] when I write a blog in picostitch without any front matter the errors are misleading
v6.0.0 (539 LOC)
- [x] MUCH better error messages when a variable was not found or some nunjucks error happens
- [x] make extended/included files also report errors nicely
- [x] make extended files across multiple
extendsalso report errors nicely - [x] nice error message for a pure.njk file if there is an error in the extended file
- [x] leaving out the extension, like
index.njkorindex.mdwhich would end up without extension after processing gets the default.html, like all other tools do, this does still allow for file names likestyle.css.njkto be processed - [x] docs: link docs in the changelog to the docs site
- [x] the
_file.numLinesFrontmattertells how many lines long is the frontmatter block, including the---lines
_config.js changes (and internals)
- [x] introduced
_file.extensionsToProcess - [x] refactor internals to only process the
filesdata as given, use_file.extensionsToProcessand be more flexible this way - [x] add optional
config.templatePaths, to allow multiple template paths, needed for the docs-kit - [x] introduce user function
preCreateProcessors()that can be used to modify theconfigobject - [x]
_file.hasFrontmatterBlockwas removed, find out if a frontmatter exists by looking into_frontmatterif you need to know it - [x] add the to-copy files to the
filesmap, so the user can modify these - [x] docs: describe the new flow in file-mapping
v5.0.0 (349 LOC)
- [x] BREAKING: rename
configureNjk()toconfigure()and pass it all processors, so the user can configure as they like - [x] BREAKING: rename "utils" to "plugins"
- [x] docs: multiple updates
- [x] docs: for
throwOnUndefineddefault configuration for nunjucks and why - [x] docs: for stats plugin
addStatsProperty(files) - [x] plugins: applying config.js files per directory, that applies to all files in that directory, and the child dirs
this is implemented in
src/plugins/configs.jsand can be called like this in apreprocess()loadDataFromConfigs(files, config)I am NOT documenting this plugin yet, I feel like it is not going to last - [x] plugins: provide
{{ _stats.lastModified.* }}and{{ _stats.files }}
v4.0.0 (339 LOC)
- [x] add
npm run build:siteto build the picossg.dev website, might move somewhere else later - [x] use _config.js instead of _nunjuck-custom/filters.js (a breaking change)
- [x] add
configas second parameter topreprocessandpostprocessfunctions, sometimes you need to know the config instead of assuming e.g. the output-path - [x] improved the docs significantly
- [x] move picossg.dev site into the repo root in the dir
picossg.devso we can- [x] use/link changelog, package.json and other files directly from the source
- [x] rename
distto_output, just to be consistent in naming - [x] ensure that the path output files are written to are child paths of the output dir, it might happen that one adds a
_outputobject which accidentally writes to places it should not (actually just happened to me), this is basically a safeguard I feel worth having
v3.0.2 (332 LOC)
- [x] add some real docs
- [x] 🐛 fixed a bug,
npm run builddid not work, I had the wrong path tobuild-cli.jsin there
v3.0.1 (332 LOC)
- [x] update the README to be useful and correct
- [x] provide example(s)
v3.0.0 (332 LOC)
- [x] rebuild tests to be at least somehow grouped/sorted
- [x]
make the components directory be _includes, just like in nunjucks no need to invent namesactually this is good as it is, the components have files that will be built and served, so its mixed purpose - [x] rewrite the processing to
- [x] provide the metadata conveniently
- [x] merge the data below on the root level deterministically, so the data are convenient to use in the template but also available in their original form (in the
_*keys) - [x] provide
_filewith all info about the original file, like filename, size, content, etc. - [x] provide
_frontmatterwith all frontmatter data - [x] provide
_outputwith the processed data, like url, content, etc. - [x] provide
_sitewith all data from the site, like url, title, description, author, etc.
- [x] merge the data below on the root level deterministically, so the data are convenient to use in the template but also available in their original form (in the
- [x] provide the metadata conveniently
- [x] allow
preprocess()andpostprocess()functions that receive ALL files incl. data and content like so:preprocess(files: Map<filename, {content: string, data: object}>)this allows processing any file before and after the main processing, it provides access to all files e.g. to find related ones and do searches - [x] no need for
picossg.*, remove it, can be done inside thepreprocess()function - [x] copy files first, and do NOT put them in the
filesmap, so they are handled first, and do not land in the processing function (preprocess and postprocess) - [x] allow post-processing, e.g. to minify pages
- [x] add absolute and relative filePath to _output, to provide where the file will be stored to
- [x] remove -i command line option, just make the includes root be the content dir, simple
v2.0.0 (281 LOC)
- [x] make
npx run @pic0/ssg -c content -o outwork in other projects - [x] allow loading njk filters
- [x] provide filter
|mdand|mdinline - [x] make a frontmatter block work
- [x] pass meta data to the template
- [x] make "extends/layout" key in frontmatter block work
- [x] allow "collecting" all metadata e.g. through picossg.pages("/blog") or so and iterate over them to generate a blog list or alike
- [x] and provide attributes for each page such as "url", ????
- [x] pass the data into the layout template too, so e.g. a
titleof a page will be seen in the _base.njk template
- [x] add _config.js/ts to allow pre-processing
v1.0.0 (138 LOC)
- [x] serve and process njk files
- [x] serve and process md files
- [x] serve and process njk.md files
- [x] serve assets, favicon, img.svg
- [x] exclude files with _
- [x] make includes work
- [x] make asset loading from components work, actually just a convention, no code for it
- [x]
generate code from e.g. JSON filescan be done in _config.js - [x]
allow running JS server side code to generate contentuse _config.js