Talenote screenshot

Talenote

Author Avatar Theme by D4rekanguok
Updated: 2 Feb 2022
65 Stars

Storybook-esque component directory for Sveltekit

Overview

TaleNote is a tool that allows developers to view and manage Svelte components within SvelteKit. It provides a Storybook-esque component directory that is embedded directly into SvelteKit’s routes directory. TaleNote aims to simplify the setup process of using Storybooks with SvelteKit for static or content-focused websites.

Features

  • List all components from a directory or more
  • View a component at different breakpoints with customizable options
  • Save snapshots of component props as “tales”

Installation

To install TaleNote, follow these steps:

  1. Install the TaleNote package.
  2. Create the necessary directory and file structure in the “routes” directory of your SvelteKit project.
  3. Set up the required files, including “__layout.reset.svelte”, “_tales.json”, “component.svelte”, “index.svelte”, and “tales.js” (or “.ts”).
  4. Configure default props and wrapper components as needed.
  5. Exclude TaleNote from production builds using the “kit.routes” feature in your svelte.config.js file.

Summary

TaleNote is a tool that simplifies the process of using Storybooks with SvelteKit for static or content-focused websites. It allows developers to view and manage Svelte components within SvelteKit’s routes directory. With features such as listing components, viewing components at different breakpoints, and saving snapshots of component props, TaleNote helps streamline the development process. Additionally, TaleNote allows for customization through configuring default props and wrapper components. Contributions to TaleNote are welcome, as it is an open-source project built by dereknguyen.