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

@saasquatch/hungry-harvest-components

v0.0.1-0

Published

1. Copy the `widget-starter` folder and rename as needed 2. Create new components in [./src/components](./src/components) as new folders, for example [./src/components/sqh-my-component](./src/components/sqh-my-component)

Downloads

60

Readme

How to build and deploy custom widgets

  1. Copy the widget-starter folder and rename as needed

  2. Create new components in ./src/components as new folders, for example ./src/components/sqh-my-component

    1. Components should be built using the HVC pattern
    2. Controller should match the name of the folder: sqh-my-component.tsx
    3. View should match the controller name + "view": sqh-my-component-view.tsx
    4. Hook should have the prefix "use" and the Controller's class name: useMyComponent.ts
    5. Stories should be added to provide visuals of each possible state of the component (MyComponent.stories.tsx) and imported into sqh-stencilbook.tsx. Be sure to import any mixins used in your components into sqh-stencilbook.scss
  3. Before you begin:

    1. Edit stencil.config.ts - update namespace to my-theme-components
    2. Edit package.json - update name to @saasquatch/my-theme-components
  4. Develop Stencil components locally

    1. npm start
    2. Edit html: index.html
  5. Build and publish to NPM under personal user to @saasquatch/[email protected]

    1. npm login
    2. npm run build
    3. npm publish --access public
  6. Implement widget in portal widget editor

    1. Reference deployed components in advanced section of the widget editor:

      dependencies:

      package: @saasquatch/mint-components
      version: 1.0.0
      filePath: /dist/mint-components/mint-components.js

      plugins:

      package: @saasquatch/mint-components
      version: 1.0.0
      filePath: /grapesjs/grapesjs.js
    2. Import custom html from index.html

  7. Test widget in browser using squatch.js library

    1. go to http://squathjs-demo.surge.sh
    2. Fill out tenantAlias, domain, user, widgetType (p/[programId]/w/referrerWidget), and jwt fields for squatch initObj in config
    3. jwt can be generated at https://jwt.io using the user object from config as the payload
      {
         "user":{
            "id":"my-user-id",
            "accountId":"my-account-id"
         }
      }
      and your tenant's API key in the Verify Signature section
    4. Reload config

flowchart