Skip to content
Hive Astro Loader has just been released! Check out on Github

Hive Astro Loader

Hive Astro Loader

Hive Astro Loader is a custom Astro loader for the Content Layer API that allows to fetch content from Hive blockchain.

About Astro

Astro is the web framework for building content-driven websites like blogs, marketing, and e-commerce. Astro is best-known for pioneering a new frontend architecture to reduce JavaScript overhead and complexity compared to other frameworks. If you need a website that loads fast and has great SEO, then Astro is for you.

Content Layer API

The Content Layer API is a new feature of Astro that allows you to fetch content for the app from any source, be it Markdown files, JSON, database, API or anything else.

Utilizing the Content Layer API, we can build a custom Astro loader that makes it very easy to fetch and present content published on the Hive blockchain.

Learn more

If you want to learn more about Astro, Content Layer API, or any of the other features of Astro, check out the links below:

Hive Astro Loader

Astro Content Layer loader for the Hive blockchain

Installation

Terminal window
npm install @onhive.io/astro-loader

or use our favorite package manager.

Usage

Hive Blog Loader

In your Astro project, edit the /src/content/config.ts:

import { defineCollection } from "astro:content";
import { hiveBlogLoader } from "@onhive.io/astro-loader";
export const collections = {
blog: defineCollection({
type: "content_layer",
loader: hiveBlogLoader("hive.coding") // Selected username
})
};

For now only hiveBlogLoader is available, more coming soon!

Learn more