Planet icon indicating copy to clipboard operation
Planet copied to clipboard

Hooks

Open Swader opened this issue 2 months ago • 1 comments

I would like to propose adding hooks to Planet, such that logic can be executed before full planet build.

Example, I am building a theme where a user can just a provide a list of video URLs and tags in a page, and mark this page as a video directory. Then, on build, I would like my pre-processor to fetch the titles and thumbnails and build the static-filtering logic for per-tag filters on this page.

I can do this dynamically by processing with JS after page-load, but this is laggy and not SEO friendly, so I would prefer a full static build according to special rules pre-deployment, which is only possible with pre-build hooks.

Swader avatar Oct 14 '25 09:10 Swader

The dynamic render works fine too (see https://bruno.eth.link/videos/) but I'd prefer if I didn't have to generate this on the fly and if it could be pre-generated.

If anyone wants to take a look at the dynamic rendering approach, the theme is here: https://github.com/Swader/planetable-kitze

Swader avatar Oct 14 '25 14:10 Swader