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

@flipdish/cdk-aspects

v0.13.0

Published

CDK Aspects for Flipdish serverless applications

Readme

@flipdish/cdk-aspects

CDK Aspects for Flipdish Serverless Applications that provide consistent AWS resource configuration and tagging across our infrastructure.

Installation

npm install @flipdish/cdk-aspects

Usage

The package provides CDK Aspects that can be used to enforce consistent configuration and tagging across your AWS resources. Import and use the aspects in your SST configuration:

import { TableSettingsAspect, TagsAspect, addAspects } from '@flipdish/cdk-aspects';

// In your SST config
export default {
  async stacks(app) {
    // Add standard aspects
    addAspects(app, [
      new TagsAspect(serviceName, datadogTeamName),
      new TableSettingsAspect(app.stage)
    ]);

    // ... rest of your stack configuration
  }
} as SSTConfig;

Available Aspects

TagsAspect

Applies consistent tagging across all resources in your stacks. This includes service name and team name tags that are useful for resource organization and cost allocation.

new TagsAspect(serviceName, teamName)

TableSettingsAspect

Enforces consistent DynamoDB table settings across your application. This aspect ensures:

  • PAY_PER_REQUEST billing mode
  • Point-in-time recovery enabled
  • Appropriate partition key (pk) and sort key (sk) naming
  • Proper removal policies based on stage (RETAIN for production, DELETE for development)
new TableSettingsAspect(stage)

Development Workflow (serverless-app-template only)

This section is only relevant if you are working within the serverless-app-template repository, where this package is maintained.

  1. Local Development:

    • During development in serverless-app-template, use @serverless-app/cdk-aspects for local testing
    • Import statements follow the pattern:
      import { TableSettingsAspect, TagsAspect, addAspects } from '@serverless-app/cdk-aspects';
  2. Production Usage:

    • The serverless-app-template bootstrap process will automatically:
      • Update dependencies to use @flipdish/cdk-aspects
      • Replace import statements accordingly
      • Remove the local aspects package

For all other projects, simply install and import @flipdish/cdk-aspects as shown in the Installation and Usage sections above.

Testing

You can verify the aspects are working correctly by checking your CloudFormation template. Here's an example using Jest/Vitest:

import { Template } from 'aws-cdk-lib/assertions';
import { App } from 'sst/constructs';

describe('DynamoDB checks', () => {
  it('All tables have billing mode PAY_PER_REQUEST', () => {
    template.allResourcesProperties('AWS::DynamoDB::Table', {
      BillingMode: 'PAY_PER_REQUEST',
    });
  });

  it('All tables have point in time recovery enabled', () => {
    template.allResourcesProperties('AWS::DynamoDB::Table', {
      PointInTimeRecoverySpecification: {
        PointInTimeRecoveryEnabled: true,
      },
    });
  });

  it('All tables should have RETAIN removal policy in production but DELETE in dev', () => {
    checkTableDeletionPolicy(template, 'Delete');
    checkTableDeletionPolicy(prodStageTemplate, 'Retain');
  });
});

License

MIT

Contributing

This package is maintained in the serverless-app-template repository.