serverless-webpack

Serverless plugin to bundle your lambdas with Webpack

MIT License

Downloads
1M
Stars
1.7K
Committers
109

Bot releases are hidden (Show)

serverless-webpack - 5.13.0 Latest Release

Published by j0k3r about 1 year ago

serverless-webpack - 5.12.0

Published by j0k3r about 1 year ago

Main Changes

This adds a new config parameter for both NPM & Yarn: copyPackageSectionNames which list entries in your package.json to copy to the output package.json (for ESM output).

What's Changed

New Contributors

Full Changelog: https://github.com/serverless-heaven/serverless-webpack/compare/v5.11.0...v5.12.0

serverless-webpack - 5.11.0

Published by j0k3r almost 2 years ago

What's Changed

New Contributors

Full Changelog: https://github.com/serverless-heaven/serverless-webpack/compare/v5.10.0...v5.11.0

serverless-webpack - 5.10.0

Published by j0k3r about 2 years ago

Main Changes

The lib is finally compatible with Yarn 2 (and above)! Thanks to @jagonzalr (and others involved in #642).
You need to define the option noNonInteractive to true in the packagerOptions in serverless.yml.

What's Changed

New Contributors

Full Changelog: https://github.com/serverless-heaven/serverless-webpack/compare/v5.9.1...v5.10.0

serverless-webpack - 5.9.1

Published by j0k3r about 2 years ago

serverless-webpack - 5.9.0

Published by j0k3r about 2 years ago

Main Changes

  1. Webpack entries can now be overridden via function option entrypoint in serverless.yml
  2. Fix a warning of undefined plugin CLI option --webpack-use-polling

What's Changed

New Contributors

Full Changelog: https://github.com/serverless-heaven/serverless-webpack/compare/v5.8.0...v5.9.0

serverless-webpack - 5.8.0

Published by j0k3r about 2 years ago

Main changes

  1. We have added a new CLI option --skip-build which has the same behavior of the previous removed CLI option --no-build. That option allows to run a function with an existing compiled output. (see https://github.com/serverless-heaven/serverless-webpack/pull/1190)

  2. We have also properly defined CLI options to remove all errors like Detected unrecognized CLI options when using Serverless > v1 (see https://github.com/serverless-heaven/serverless-webpack/pull/1187)

What's Changed

New Contributors

Full Changelog: https://github.com/serverless-heaven/serverless-webpack/compare/v5.7.1...v5.8.0

serverless-webpack - 5.7.1

Published by j0k3r over 2 years ago

serverless-webpack - 5.7.0

Published by j0k3r over 2 years ago

Main changes

  1. @medikoo changed the output log when using Serverless v3, it's less verbose and more clean

    progress:

    success:

  2. We switch back to archiver instead of bestzip to ensure consistent artifact. The switch to bestzip was mostly for faster zip because it tend to use the native zip command instead of the one from Node.

  3. Support for NPM 8 was added by @moroine

What's Changed

New Contributors

Full Changelog: https://github.com/serverless-heaven/serverless-webpack/compare/v5.6.1...v5.7.0

serverless-webpack - 5.6.1

Published by j0k3r over 2 years ago

What's Changed

Full Changelog: https://github.com/serverless-heaven/serverless-webpack/compare/v5.6.0...v5.6.1

serverless-webpack - 5.6.0

Published by j0k3r almost 3 years ago

Detailed changes

  1. There is now a noInstall options in packagerOptions (for both NPM & Yarn) to skip deps installation during the Serverless package / deployment. If you enable that option, be sure packages are installed before.

    custom:
      webpack:
        packagerOptions:
          noInstall: true
    
  2. The --no-build CLI argument has been removed.
    You should now define it inside your Serverless configuration:

    custom:
      webpack:
        noBuild: true
    
  3. The --watch CLI argument has been improved and now works properly.

What's Changed

Full Changelog: https://github.com/serverless-heaven/serverless-webpack/compare/v5.5.5...v5.6.0

serverless-webpack - 5.5.5

Published by j0k3r about 3 years ago

serverless-webpack - 5.5.4

Published by j0k3r about 3 years ago

This release include one fix (#953) when using serverless-webpack with webpack >= 5.52.0

serverless-webpack - 5.5.3

Published by j0k3r about 3 years ago

This release include one fix (#944 thanks @mostthingsweb) when using sls deploy function --function=function-name for a function defined without an explicit runtime (that bug were introduced in 5.5.2).

serverless-webpack - 5.5.2

Published by j0k3r about 3 years ago

Here is a small release with few fixes.

  • Register serverless as peer dependency (#900 @medikoo)
  • Do not run webpack on a single non-node function (#879 @j0k3r)
  • Skip container function with uri defined (#877 @j0k3r)
serverless-webpack - 5.5.1

Published by j0k3r over 3 years ago

Here is a small release with few fixes with one important improvement in memory usage when packaging function individually.

Thanks to contributors! 🤝

  • Use processed options to improve non-AWS provider support (#834 @CorentinDoue)
  • Reduce memory usage by releasing webpack stats objects after compile (#858 @janicduplessis)
  • Allow boolean or number values in slsw.lib.options (#857 @coyoteecd)
  • Fix packaging for non-node functions (#876 @FatalTouch)
serverless-webpack - 5.5.0

Published by j0k3r over 3 years ago

New features were added in that release 🎉

Again, thanks to contributors! 🤝

We added the ability to specify the node_modules relative dir

In #689, thanks to @ypxing

This'll help people using monorepo. You define this option like that:

# serverless.yml
custom:
  webpack:
    includeModules:
      nodeModulesRelativeDir: '../../' # relative path to current working directory.

Fix the spawn E2BIG error when zipping

In #813, thanks to @j0k3r

While fixing a bug when using the excludeRegex option a new one appear when we give a huge files list to the zip command. It crashed with the E2BIG error.
Now, if you define the excludeRegex option, we'll never use the zip command but the NodeJS way to create the zip to avoid that error. It'll be slower but it'll work.

Extends the --no-build option to serverless offline start

In #770, #649 & #501, thanks to @nponeccop, @francisu & @todda00

Extends the --no-build option to serverless offline start and serverless offline, allowing the ability to use previously compiled files from either a previous serverless offline start (when keeping output files) or from a direct serverless webpack

Add Serverless Container Support

In #723, thanks to @rogersgt

It adds support for Docker Images as Custom Runtimes. Check the doc about that: https://github.com/serverless-heaven/serverless-webpack#support-for-docker-images-as-custom-runtimes

Add support for Yarn network-concurrency option

In #550, thanks @cfroese

It adds the ability to specify the network-concurrency option when using Yarn as the packager.

# serverless.yml
custom:
  webpack:
    packager: 'yarn'
    packagerOptions:
      networkConcurrency: 1

Full changelog

  • Add ability to specify the node_modules relative dir #689
  • Fix the spawn E2BIG error when zipping #813
  • Extends the --no-build option to serverless offline start #770
  • Add Serverless Container Support #723
  • Add support for Yarn network-concurrency option #550
serverless-webpack - 5.4.2

Published by j0k3r over 3 years ago

Finally, some annoying bugs introduced in 5.4.0 are now fixed. Thanks to contributors! 🤝

  • Regression Fix: Empty lines while stats: 'errors-only' (#773 @Enase)
  • Add type to CLI options (#774 @j0k3r)
  • Add Serverless v2 compatibility (#775 @nponeccop)
  • Support local errors with NPM 7 workspaces (#782 @mikejpeters)
  • Fix excludeRegex option and allow dotfiles to be packaged (#780 @l1b3r)
  • Correctly handle packaging for function during deploy -f (#794 @pgrzesik)

The next release will be the 5.5.0 with some additional features ✨

serverless-webpack - 5.4.1

Published by j0k3r over 3 years ago

Here is a small release with few fixes. Thanks to contributors! 🤝
There are still some bugs reported since 5.4.0 was released that we need to work on.

  • Display the zip method used (#735 @j0k3r)
  • Dependabot should now updates package.json too (#742 @j0k3r)
  • Fix configuration check for keepOutputDirectory in cleanup (#748 @daryl-c)
  • Prevent ts-node being registered twice (#766 @apancutt)
  • Fix external modules with webpack 5 (#746 @janicduplessis)
  • Allow custom webpack config files to export as an ES6 module (interop default) (#767 @apancutt)
serverless-webpack - 5.4.0

Published by j0k3r over 3 years ago

After a long silence, here the latest release ✌️
We have new options, new arguments and some optimizations 🚀

📚 The full changelog is available here. But here are some highlights:

New options:

  • noFrozenLockfile (boolean) under the packagerOptions for the Yarn packager allows you to not have an up to date yarn.lock. See #687
  • excludeRegex (string) allows you to filter files that match the regex before adding to the zip. See #612
  • serializedCompile (boolean) allows you to run each webpack buid one at a time to reduce memory usage. See #517
  • allowCustomRuntime (boolean) added to the function level in your serverless.yml allows you force the packaging when you are using a nodejs custom runtime ONLY. See #675
  • concurrency (integer) allow to set the concurrency (defaults to the number of available cores), only works when packing functions individually. See #681

New arguments:

  • the --no-build used when deploying won't re-build everything if you already build it (using sls webpack for example). See #560

Optimizations:

  • switched to bestzip instead of archiver to use natine zip command if it exists. See #596
  • speed up cleanup process when removing .webpack folder. See #462
Package Rankings
Top 0.95% on Npmjs.org
Top 8.17% on Proxy.golang.org
Badges
Extracted from project README
Serverless License NPM Build Status Coverage Status Contributors NPM NPM
Related Projects