contentlayerdev / contentlayerdev/contentlayer

Preprocessing and Postprocessing Hooks?

Đang mở
#325 1 bình luận 0 reaction 0 người được giao Xem trên GitHub
help wanted meta: never-stale needs-research
Ngôn ngữ chính
TypeScript
Star
3.5k
Fork
192
Chỉ số merge pull request
Không có pull request nào được merge trong 30 ngày

Mô tả

I have a metalsmith site I'd like to move over or integrate with contentlayer.

Unlike CL, Metalsmith has straightforward ways of looking at the whole collection while processing individual documents. This allows, for example, ensuring that all internal website links are to documents that already exist. MS also has a large library of useful plugins.

Is there a way to hook metalsmith into content layer reloading, so it is run first before content layer? Or more directly use metalsmith to process files within content layer itself. As a work around, I suppose, I could use metalsmith to generate a directory of json files that is then used as input to content layer. But this requires basically managing two content systems.

Alternatively, is there a way to hook into the contentlayer process with content processors that can transform individual documents while having access to all collections?

Hướng dẫn đóng góp

Mở hướng dẫn đóng góp

Đánh giá

Issue này chưa được đánh giá.

Nhận issue mới trong hộp thư của bạn

Bản tóm tắt ngắn những issue GitHub phù hợp với người mới.