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

bamboo-lambda

v1.0.2

Published

Bamboos Serverless Stack

Readme

Bamboo Lambda

Our serverless stack.

Setup

  • yarn install - install the dependencies
  • cp src/config/example.local.config.json src/config/local.config.json to setup the config then fill in the bits. You may need API keys from one of the other devs. The rest of the config values will be set automatically after you first run yarn deploy

Scripts

  • yarn dev starts what you need to begin developing
  • yarn test:unit executes the unit tests
  • yarn test:integration executes the integration tests (against the actual server)
  • yarn test:integration:only TEST executes just that one test (or group of tests if you use describe())
  • yarn test:integration:quick executes all integration tests except for some that take a long time (Basiq)
  • yarn test executes all tests once
  • yarn test:unit:watch exectutes unit tests in watch mode
  • yarn log FUNCTION starts logging the function name
  • yarn invoke FUNCTION calls the function and returns the logs
  • yarn deploy:only FUNCTION deploys just that function, useful for rapid iterative development
  • yarn deploy deploys the entire serverless stack and runs some post-deploy scripts
  • yarn pretty runs prettier on the whole project, make sure you commit before running this so not to confuse your commit
  • yarn set:stage STAGE will update your local config with the parameters pulled from cloud formation (you need the AWS CLI installed for this)

Testing

  • There are unit test which run before the build and are run in watch mode as part of yarn dev. These should test internal business logic
  • Integration tests after deploy and make actual calls to the server to test end-to-end functionality
  • If you need to see what fetch calls are being made in your src/config/local.config.json add "LOG_FETCH": true, and now fetch calls should be logged to the console.

Deploying - READ!!

  • There is a known issue currently with deploying new stack. If you are deploying for the first time you will get errors unless you comment out the line that reads AWS_USER_POOL_ID: ${cf:${self:custom.stackName}.UserPoolId} from serverless.yml. This is because we are trying to get the UserPoolID from the current stack, but it needs the stack to be deployed already before it can do that. On the second deploy you can put the line back in again and it should be fine. This is a known issue and we are trying to work through it on this issue: https://github.com/serverless/serverless/issues/4940

Coding Standards

  • This project runs a pre-commit git hook that executes "prettier" on changed files to ensure a common coding standard

Request Response Flow

  1. CLIENT => 2) GATEWAY => 3) HANDLER => 4) DOMAIN => 5) HANDLER => 6) GATEWAY => 7) CLIENT

  2. Client initiates a request to the gateway

  3. Gateway authorizes the request and passes to the lambda handler

  4. Handler validates input and translates into a strong type before passing to the domain

  5. Domain performs the actual logic for the call, can be assured that the input has been validated

  6. Handler translates the domain response into the expected response from client

  7. Response passes back through gateway before..

  8. Client recieves response

Visual Studio Code

If you are using Visual Studio code for editing we have some reccomended extensions and settings:

Extensions

Other

  • To build the cognito-user-pool.yml I ran aws cognito-idp describe-user-pool --region ap-southeast-2 --user-pool-id ap-southeast-2_aaWkuRqqc then copied over the result
  • We are using --forceExit on the integration tests because of this issue in jest: https://github.com/facebook/jest/issues/6639