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 🙏

© 2024 – Pkg Stats / Ryan Hefner

gatsby-source-formspree

v0.0.2

Published

A Gatsby source plugin that fetches formspree submissions

Downloads

7

Readme

Description

The gatsby-source-formspree plugin uses Formspree's API to fetch form submissions. This allows Gatsby site creators to include user submissions in their website output.

Learning Resources (optional)

You can find out more about Formspree here and the Formspree API here.

How to install

To install it, in the root of your site run:

npm install --save gatsby-source-formspree

Then add the plugin to your gatsby-config.js file including your form ID and API key:

  {
    resolve: "gatsby-source-formspree",
    options: {
      form: "YOUR_FORM_ID",
      key: "YOUR_API_KEY",
    },
  },

You can obtain your form ID by creating a new form in the Formspree dashboard and then copying the 6 digit ID from the form's URL. See Getting your form's hashid in the Formspree help docs.

To create an API key, go into the new form's settings panel and enable the API. Then copy your read-only key and add it to the gatsby config. See API Keys in the Formspree help docs.

When do I use this plugin?

This plugin could be used any time you want to display user submitted content on your website. Here are some ideas:

  • You could use it to show a list of people who have RSVP'd for an event
  • You could create an online guest book for a wedding
  • You could automatically update your company's team page. This would require a separate password-protected form where employees could upload an short bio and an image.
  • You could create a full comment system.

Each of these ideas could be coupled with a deploy hook to rebuild your site when a form is submitted.

Examples of usage

This usually shows a code example showing how to include this plugin in a site's config.js file.

code example

//See this Markdown Cheatsheet on how to format code examples.

This section could also include before-and-after examples of data when the plugin is enabled, if applicable.

How to query for data (source plugins only)

If this is a source plugin README, source plugins ought to allow people to query for data within their Gatsby site. Please include code examples to show how to query for data using your source plugin.

How to run tests

How to develop locally

How to contribute

If you have unanswered questions, would like help with enhancing or debugging the plugin, it is nice to include instructions for people who want to contribute to your plugin. Starter README template