Skip to content
New issue

Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? # to your account

Not compiling all files #105

Open
ValiDraganescu opened this issue Jul 14, 2018 · 0 comments
Open

Not compiling all files #105

ValiDraganescu opened this issue Jul 14, 2018 · 0 comments

Comments

@ValiDraganescu
Copy link

ValiDraganescu commented Jul 14, 2018

Hi. I'm using this plugin on a small project with AWS Lambda. Now I want to add a Lambda authorizer function. The problem is that the plugin does not compile the atuthorizer.ts file. I also noticed that a remnant class that is not used anymore, ie. not referenced by any other file, is not compiled and not included in the build folder. This looks like a neat feature as it keeps the build folder clean, but I want my authorizer function which is referenced just in the serverless.yml file.

Here is the error I got

Serverless: Using local tsconfig.json
{ file: undefined,
  start: undefined,
  length: undefined,
  messageText: 'File \'build/src/routes/authorizer.ts\' not found.',
  category: 1,
  code: 6053,
  reportsUnnecessary: undefined }

Do you have any idea what do I need to do to compile or add this file to the build folder?
I also tried to add it in the package: include section but it's still not there ( and if it wold be copied, it would be ts and not js)

Later Edit: if I run tsc, all the files are compiled as they should.

Later, later edit:
BTW, I want my json schema files to be bundled in the .build folder but I just can't find it there, I need them for ajv validator and swagger

package:
  include:
    - ./src/**/*.json

Thank you!

LE: it was just me not paying attention, the correct authorizer path should have been src/routes/authorizer.ts, after I corrected it, the authorizer is compiled as it should and the json files are also copied to the .build forlder

# for free to join this conversation on GitHub. Already have an account? # to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant