npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2026 – Pkg Stats / Ryan Hefner

@vigilkids/section-renderer-vue

v0.6.1

Published

Vue 3 adapter for OneX Section Renderer SDK

Downloads

988

Readme

@vigilkids/section-renderer-vue

Vue 3 rendering engine for OneX Section system. Renders section-based content with product-aware component resolution, lazy loading, inline editing, and editor preview support.

Install

pnpm add @vigilkids/section-renderer-vue

Peer Dependencies:

  • vue ≥ 3.4

Usage

Frontend (Nuxt/Vue app)

<script setup>
import { SectionRenderer, registerArticleSections, SectionRendererPlugin } from '@vigilkids/section-renderer-vue'

// Register built-in article sections (call once at app startup)
registerArticleSections()
</script>

<template>
  <SectionRenderer
    :sections-data="article.content_json"
    :product-code="'visiva'"
  />
</template>

Admin Preview (iframe)

import { createPreviewApp } from '@vigilkids/section-renderer-vue/editor'

createPreviewApp('#app', {
  bridge: { send, on },
  onSectionClick: (id) => { /* select section */ },
})

Product Styles

// Import product-specific article CSS
import '@vigilkids/section-renderer-vue/styles/vigilkids'
import '@vigilkids/section-renderer-vue/styles/visiva'

Raw HTML Utility Classes

适用于 article-custom-html 或原始 HTML 模板,作用域限定在 .article-content

  • 间距:mt-{n} mb-{n} ml-{n} mr-{n} p-{n} px-{n} py-{n}
  • 自动居中:ml-auto mr-auto mx-auto
  • 布局:block inline-block
  • 宽度:w-full w-fit
  • 字号:text-12 ~ text-36
  • 字重:font-normal font-medium font-semibold font-bold font-black
  • 对齐:text-left text-center text-right
  • 行高:leading-tight leading-normal leading-relaxed leading-loose

示例:

<img class="block w-fit mx-auto mb-20" src="..." alt="..." />
<p class="mb-20 text-18 font-bold">%base_year%</p>

Components

| Component | Purpose | |-----------|---------| | SectionRenderer | Root renderer — iterates sections, resolves components | | SectionWrapper | Per-section container with editor-mode highlights | | LazySection | IntersectionObserver lazy loading with CLS prevention | | SectionErrorBoundary | Graceful error fallback per section | | FallbackSection | Placeholder for unregistered section types |

Composables

| Composable | Purpose | |------------|---------| | useInlineEdit | contentEditable inline text editing (double-click to edit) | | useRegistry | Product-aware section component registration and resolution | | useSectionStyle | Semantic tokens → Tailwind classes + inline styles | | useSectionSEO | JSON-LD structured data generation | | useLazyRender | IntersectionObserver visibility detection |

Section Components

28 article sections across 2 products (VigilKids + Visiva) + 2 shared:

article-heading, article-subheading, article-image, article-bullet-list, article-step-list, article-notice, article-quote, article-question, article-pros-cons, article-feature, article-cta, article-faq, article-table, article-toc, article-custom-html

Compatibility

  • Vue ≥ 3.4
  • Node.js ≥ 18
  • ESM only

License

MIT