BETA

Home · Blog · Download · Docs · About

Quick Start Guide

  1. Download the executable for your operating system.

  2. Initialize your database.

    bigblog init blog.db --force
    
  3. Add content to the blog database.

    bigblog add blog.db --directory './posts' --include **/*.md
    
  4. Add the BigBlog.SDK package to your project.

    dotnet package add BigBlog.SDK
    
  5. Copy the database into your app and start blogging!

    using BigBlog;
    
    var builder = WebApplication.CreateBuilder(args);
    builder.Services.AddBigBlog("blog.db");
    
    // IBigBlogReader can be injected to your page
    public class BlogModel : PageModel
    {
        private readonly IBigBlogReader _blog;
    
        public BlogModel(IBigBlogReader blog)
        {
            _blog = blog;
        }
    
        public IReadOnlyList<BlogPost> Posts { get; private set; } = [];
    
        public async Task OnGet()
        {
            this.Posts = await _blog.GetAllPostsAsync();
        }
    }
    
< back