Open serg06 opened 2 years ago
@serg06 Are you stating that you have typescript
listed in service devDependencies
, yet it gets packaged for lambda (even though exclusion of dev dependencies is applied) ?
@medikoo Yes exactly.
@serg06 will it happen also if you run sls package
but with no plugins
section in serverless.yml
(I know it will create not working artifact, but I want to confirm whether any plugin influences that)
@medikoo I can confirm that typescript
is still included in the package, with excludeDevDependencies: true
, using serverless ^3.15. No extra plugin.
Is there any solution to this?
IIRC I fixed it by adding this to serverless.yaml:
package:
patterns:
- '!node_modules/typescript/**'
Does that work? @gualopezb
Yes, it does the trick. I was just wondering if this is indeed an issue with the serverless-plugin-typescript
module and, if so, is it going to be fixed in a future version?
yarn.lock
, no package has typescript as a dependencypackage.json
it's underdevDependencies
serverless.yml
I haveexcludeDevDependencies: true
Yet for some reason when I run
sls package
, it's included undernode_modules/typescript
(and it's 60MB large!)Tried with versions: