Skip to content
New issue

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

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

Already on GitHub? Sign in to your account

Support Typescript #17

Closed
azai91 opened this issue Dec 20, 2019 · 1 comment
Closed

Support Typescript #17

azai91 opened this issue Dec 20, 2019 · 1 comment

Comments

@azai91
Copy link

azai91 commented Dec 20, 2019

Expected Behavior

It would be great to have support with the typescript serverless plugin (generate .ts files instead of .js files in datadog handler)

Actual Behavior

An error is thrown where the typescript plugin is looking for ts files but the dd plugin only generates .js files.

Steps to Reproduce the Problem

  1. sls deploy --noDeploy in a typescript project with the typescript and dd plugin

Specifications

  • Serverless Framework version:
  • Datadog Serverless Plugin version:
  • Lambda function runtime (Python 3.7, Node 10, etc.): Node 10

Stacktrace

Serverless: Auto instrumenting functions with Datadog
Serverless: Adding Lambda Layers to functions
Serverless: Compiling with Typescript...
Serverless: Using local tsconfig.json
{ file: undefined,
start: undefined,
length: undefined,
messageText:
 "File 'datadog_handlers/clear-business-credits.ts' not found.",
category: 1,
code: 6053,
reportsUnnecessary: undefined }

Type Error ---------------------------------------------

TypeError: Cannot read property 'getLineAndCharacterOfPosition' of undefined
@DarcyRaynerDD
Copy link
Collaborator

DarcyRaynerDD commented Jan 27, 2020

Hi @azai91, sorry for the late reply. We just released a version that should be compatible with serverless-plugin-typescript, (v0.13.0). If you get a chance, we'd love to hear any feedback on whether this solves your issue.

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

No branches or pull requests

2 participants