JavaScript runtime features for CloudFront Functions (original) (raw)
The CloudFront Functions JavaScript runtime environment is compliant with ECMAScript (ES) version 5.1 and also supports some features of ES versions 6 through 12.
For the most up-to-date features, we recommend that you use JavaScript runtime 2.0.
The JavaScript runtime 2.0 features has the following changes compared to 1.0:
- Buffer module methods are available
- The following non-standard string prototype methods are not available:
String.prototype.bytesFrom()
String.prototype.fromBytes()
String.prototype.fromUTF8()
String.prototype.toBytes()
String.prototype.toUTF8()
- The cryptographic module has the following changes:
hash.digest()
– Return type is changed toBuffer
if no encoding is providedhmac.digest()
– Return type is changed toBuffer
if no encoding is provided
- For more information about additional new features, see JavaScript runtime 2.0 features for CloudFront Functions.
Topics
Event structure
JavaScript runtime 1.0 features
Did this page help you? - Yes
Thanks for letting us know we're doing a good job!
If you've got a moment, please tell us what we did right so we can do more of it.
Did this page help you? - No
Thanks for letting us know this page needs work. We're sorry we let you down.
If you've got a moment, please tell us how we can make the documentation better.