Serverless Parcel

homepage icon https://github.com/johnagan/serverless-parcel
Follow @johnagan

Tracked

NPM Downloads Last Month
27
Issues
1
Stars
3
Forks
2
Watchers
3
Watch Star Fork Issue Download License NPM Build Status Coverage Status Contributors

Repo README Contents:

serverless-parcel

Serverless plugin for zero-config parcel bundler support.

Install

yarn add serverless-parcel --dev

Add the plugin to your serverless.yml:

plugins:
  - serverless-parcel

Configure

None required! By default, parcel will build your lambda functions with parcel… but if you want to get fancy, here ya go:

custom:
  parcel:
    ## options for lambda functions
    options:
      ## defaults
      target: node
      cache: false
      watch: false
      bundleNodeModules: true
      outDir: autogenerated - you can't change this

    ## non-lambda entries you'd like to build
    entries:
      # an array of bundler options with an entry file
      - file: src/index.html
        minify: true
        target: browser
      - file: src/admin.html
        minify: false
        sourceMaps: true

A full list of options can be found on parcel’s api docs

Shout Out

This project was heavily inspired by serverless-plugin-typescript and serverless-webpack. Both are epic projects and I hope this projects grows up to be like them one day. :tada: