Skip to content

Commit

Permalink
docs(lambda): JSDoc Markdown code block
Browse files Browse the repository at this point in the history
  • Loading branch information
nmussy committed Mar 4, 2024
1 parent b19f822 commit ae37705
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions packages/aws-cdk-lib/aws-lambda/lib/event-source-mapping.ts
Original file line number Diff line number Diff line change
Expand Up @@ -292,8 +292,10 @@ export interface IEventSourceMapping extends cdk.IResource {
* Usually, you won't need to define the mapping yourself. This will usually be done by
* event sources. For example, to add an SQS event source to a function:
*
* import { SqsEventSource } from 'aws-cdk-lib/aws-lambda-event-sources';
* lambda.addEventSource(new SqsEventSource(sqs));
* ```ts
* import { SqsEventSource } from 'aws-cdk-lib/aws-lambda-event-sources';
* lambda.addEventSource(new SqsEventSource(sqs));
* ```
*
* The `SqsEventSource` class will automatically create the mapping, and will also
* modify the Lambda's execution role so it can consume messages from the queue.
Expand Down

0 comments on commit ae37705

Please sign in to comment.