@smithy/core
[![NPM version](https://img.shields.io/npm/v/@smithy/core/latest.svg)](https://www.npmjs.com/package/@smithy/core) [![NPM downloads](https://img.shields.io/npm/dm/@smithy/core.svg)](https://www.npmjs.com/package/@smithy/core)
Last updated 9 months ago by smithy-team .
Apache-2.0 · Repository · Bugs · Original npm · Tarball · package.json
$ npm install @smithy/core 
SYNC missed versions from official npm registry.

@smithy/core

NPM version NPM downloads

An internal package. You probably shouldn't use this package, at least directly.

This package provides common or core functionality for generic Smithy clients.

You do not need to explicitly install this package, since it will be installed during code generation if used.

Development of @smithy/core submodules

Core submodules are organized for distribution via the package.json exports field.

exports is supported by default by the latest Node.js, webpack, and esbuild. For react-native, it can be enabled via instructions found at reactnative.dev/blog, but we also provide a compatibility redirect.

Think of @smithy/core as a mono-package within the monorepo. It preserves the benefits of modularization, for example to optimize Node.js initialization speed, while making it easier to have a consistent version of core dependencies, reducing package sprawl when installing a Smithy runtime client.

Guide for submodules

  • Each index.ts file corresponding to the pattern ./src/submodules/<MODULE_NAME>/index.ts will be published as a separate dist-cjs bundled submodule index using the Inliner.js build script.
  • create a folder as ./src/submodules/<SUBMODULE> including an index.ts file and a README.md file.
    • The linter will throw an error on missing submodule metadata in package.json and the various tsconfig.json files, but it will automatically fix them if possible.
  • a submodule is equivalent to a standalone @smithy/<pkg> package in that importing it in Node.js will resolve a separate bundle.
  • submodules may not relatively import files from other submodules. Instead, directly use the @scope/pkg/submodule name as the import.
    • The linter will check for this and throw an error.
  • To the extent possible, correctly declaring submodule metadata is validated by the linter in @smithy/core. The linter runs during yarn build and also as yarn lint.

When should I create an @smithy/core/submodule vs. @smithy/new-package?

Keep in mind that the core package is installed by all downstream clients.

If the component functionality is upstream of multiple clients, it is a good candidate for a core submodule. For example, if middleware-retry had been written after the support for submodules was added, it would have been a submodule.

If the component's functionality is downstream of a client (rare), or only expected to be used by a very small subset of clients, it could be written as a standalone package.

Current Tags

  • 2.5.4                                ...           latest (a month ago)

52 Versions

  • 2.5.4                                ...           a month ago
  • 2.5.3                                ...           a month ago
  • 2.5.2                                ...           a month ago
  • 2.5.1                                ...           2 months ago
  • 2.5.0                                ...           2 months ago
  • 2.4.8                                ...           3 months ago
  • 2.4.7                                ...           3 months ago
  • 2.4.6                                ...           3 months ago
  • 2.4.5                                ...           3 months ago
  • 2.4.4                                ...           3 months ago
  • 2.4.3                                ...           3 months ago
  • 2.4.2                                ...           3 months ago
  • 2.4.1                                ...           4 months ago
  • 2.4.0                                ...           4 months ago
  • 2.3.2                                ...           5 months ago
  • 2.3.1                                ...           5 months ago
  • 2.3.0                                ...           5 months ago
  • 2.2.8                                ...           5 months ago
  • 2.2.7                                ...           5 months ago
  • 2.2.6                                ...           6 months ago
  • 2.2.5                                ...           6 months ago
  • 2.2.4                                ...           6 months ago
  • 2.2.3                                ...           6 months ago
  • 2.2.2                                ...           6 months ago
  • 2.2.1                                ...           6 months ago
  • 2.2.0                                ...           7 months ago
  • 2.1.1                                ...           7 months ago
  • 2.1.0                                ...           7 months ago
  • 2.0.1                                ...           7 months ago
  • 2.0.0                                ...           7 months ago
  • 1.4.2                                ...           9 months ago
  • 1.4.1                                ...           9 months ago
  • 1.4.0                                ...           9 months ago
  • 1.3.8                                ...           9 months ago
  • 1.3.7                                ...           10 months ago
  • 1.3.6                                ...           10 months ago
  • 1.3.5                                ...           10 months ago
  • 1.3.4                                ...           10 months ago
  • 1.3.3                                ...           10 months ago
  • 1.3.2                                ...           a year ago
  • 1.3.1                                ...           a year ago
  • 1.3.0                                ...           a year ago
  • 1.2.2                                ...           a year ago
  • 1.2.1                                ...           a year ago
  • 1.2.0                                ...           a year ago
  • 1.1.0                                ...           a year ago
  • 1.0.5                                ...           a year ago
  • 1.0.4                                ...           a year ago
  • 1.0.3                                ...           a year ago
  • 1.0.2                                ...           a year ago
  • 1.0.1                                ...           a year ago
  • 1.0.0                                ...           a year ago

© 2010 - cnpmjs.org x YWFE | Home | YWFE