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

@stack-spot/jinja-forms

v0.7.1

Published

TODO

Readme

Jinja Forms

TODO

Installation

pnpm add @stack-spot/jinja-forms

Open your package.json and add to scripts.postinstall the following:

{
  "scripts": {
    "postinstall": "pnpm pyodide"
  }
}

Now run pnpm i.

Usage

Example:

import { Button, Flex } from '@citric/core'
import mock from './forms-mock.json' // a mock with a json describing a form
import mock2 from './forms-mock-2.json' // a mock with a json describing a form
import { accountVars, authVars, pluginVars, stackVars, workspaceVars } from './variables-mock' // mocked values for variables
import { ConnectionInterfaceConfig, ConnectionInterfaceConfigProvider, DynamicForm, GlobalContext, VariablesContext } from '@stack-spot/jinja-forms'

const connectionsMock: ConnectionInterfaceConfig = {
  getConnectionInterfaces: () => Promise.resolve(['connection1', 'connection2']), // gets the connections interfaces to be used in the form
  isConnectionInterfaceNameAvailable: (value) => Promise.resolve(false), // checks if the name for a connection interface is available
}

export const FormsTest = () => (
  <ConnectionInterfaceConfigProvider value={connectionsMock}> {/* Allows connection interface fields to be used in the child forms */}
    <VariablesContext account={accountVars} workspace={workspaceVars} auth={authVars} stack={stackVars}> {/* Tells which variables are available to the child forms */}
      <GlobalContext> {/* Uses a global context common to all child forms. Useful for sharing data among different forms. */}
        <h1>Form 1</h1>
        <DynamicForm {/* The form itself */}
          name="test"
          inputs={mock.inputs as any} {/* This is the field "inputs" that normally comes from the backend. It describes the form fields. */}
          computedInputs={mock.computedInputs} {/* This is the form data that is computed. This data can be used by the fields. Optional. */}
          globalComputedInputs={mock.globalComputedInputs} {/* This is the form data that is computed and global. This data can be used by the fields. Optional. Requires a GlobalContext. */}
          envs={['dev', 'stg', 'prd']} {/* The environments available for the form. Fields that are "by env" will be able to be set for each environment */}
          pluginVariables={pluginVars} {/* If this is a plugin form, it might need plugin variables. This is where you pass these variables. Optional. */}
          onSubmit={console.log} {/* What to do when the form is submit. It receives the form object, which contains many things among all fields with their current values. */}
        >
          <Flex style={{ marginTop: '20px' }}>
            <Button type="reset" colorScheme="inverse">Reset</Button>
            <Button type="submit">Submit</Button>
          </Flex>
        </DynamicForm>
        {/* Another example, a second form. */}
        <h1>Form 2</h1>
        <DynamicForm name="test2" inputs={mock2.inputs as any} globalContext="global" envs={['dev', 'stg', 'prd']} onSubmit={console.log}>
          <Flex style={{ marginTop: '20px' }}>
            <Button type="reset" colorScheme="inverse">Reset</Button>
            <Button type="submit">Submit</Button>
          </Flex>
        </DynamicForm>
      </GlobalContext>
    </VariablesContext>
  </ConnectionInterfaceConfigProvider>
)

This example has been taken from here: https://github.com/stack-spot/portal-edp/blob/feat-jinja-forms-rework/src/views/FormsTest.tsx

With the link above you can also check the code for the mocks used.