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

@formvue/embed-astro

v0.1.0

Published

Native Astro component for FormVue lead-capture embeds with zero UI-framework configuration.

Readme

@formvue/embed-astro

Native Astro component for embedding FormVue lead-capture widgets. It needs no React, Preact, Astro renderer integration, or handwritten browser initialization.

Install

pnpm add @formvue/embed-astro

Use

---
import { FormVueEmbed } from "@formvue/embed-astro";
---

<FormVueEmbed formId="your-form-id" />

inline is the default mode. The other FormVue modes use the same component:

<FormVueEmbed mode="modal" formId="your-form-id" id="embed-config-id" />
<FormVueEmbed mode="contact" formId="your-form-id" id="embed-config-id" />
<FormVueEmbed mode="content" formId="your-form-id" id="embed-config-id" />

The component loads the matching production SDK bundle from https://cdn.formvue.com/v1 once per mode per page, mounts it in an isolated Shadow DOM, and destroys it automatically when Astro removes the component. It also works with Astro client-side navigation because each <formvue-embed> instance owns its mount and cleanup lifecycle.

id is required for modal, contact, and content modes. The component rejects a missing or empty identifier during Astro rendering instead of shipping a widget that silently does nothing.

Common options

SDK options are regular component props:

<FormVueEmbed
  formId="your-form-id"
  text="Start Your Free Estimate"
  size="lg"
  width="full"
  attribution={{
    campaignSlug: "auto",
    passQueryParams: true,
  }}
/>

Use sdkBaseUrl="https://cdn.formvue.com/preview" to test preview SDK bundles. Each mode's SDK loads once per page: the first-loaded bundle wins, so a manual CDN <script> tag or a different sdkBaseUrl on another embed of the same mode is reused instead of loading again. When that happens, a console warning reports the requested URL that was ignored. Use fallbackUrl, fallbackText, and minHeight to customize the no-script or SDK-load failure state.

Browser events

The component emits bubbling DOM events so analytics can be added without a UI framework wrapper:

| Event | event.detail | |---|---| | formvue:ready | { formId, mode } | | formvue:submit | { phone } | | formvue:success | { data } | | formvue:error | { error, phase } | | formvue:preview-submit | { payload } |

<FormVueEmbed formId="your-form-id" class="estimate-form" />

<script>
  document.addEventListener("formvue:success", (event) => {
    const { data } = (event as CustomEvent).detail;
    (window as Window & { dataLayer?: unknown[] }).dataLayer?.push({
      event: "formvue_success",
      formVueData: data,
    });
  });
</script>

WordPress shell with Astro content

Place <FormVueEmbed> in the Astro-owned page or shared page template. It does not need to be added to a WordPress header, navigation, or plugin. FormVue's Shadow DOM prevents WordPress theme CSS from changing the widget.

If the site uses a Content Security Policy, allow https://cdn.formvue.com in script-src and the configured FormVue origins in connect-src and img-src.

Agent-assisted installation

This repository includes skills/formvue-astro-install, a portable Agent Skill that can install and verify the package in another Astro repository. Copy that folder to .agents/skills/ for Codex or .claude/skills/ for Claude Code, then ask the agent to install FormVue with the form ID and intended placement.