Skip to content

Latest commit

 

History

History
 
 

webassembly

Folders and files

NameName
Last commit message
Last commit date

parent directory

..
 
 
 
 
 
 
 
 
 
 

AWS SDK for Rust code examples using WebAssembly

Purpose

This example demonstrates how to package in an WebAssembly module that uses the developer preview version of the AWS SDK for Rust.

Code examples

Running the code examples

Prerequisites

⚠ Important

Your must customize your AWS credentials in the file www/env/credentials.js. Otherwise, it will not make the request to the backend.

count-functions

This example lists your Lambda functions and returns the total amount found in a certain Region.

wasm-pack build --target web --out-dir www/pkg --dev

From within the www directory, run the following command to install project and start serving.

npm ci
npm start

Access your page at http://localhost:3000. Make your selection and press Run:

  • region is the Region in which the client is created. If not supplied, defaults to us-west-2.
  • verbose displays additional information.

Resources

Contributing

To propose a new code example to the AWS documentation team, see CONTRIBUTING.md. The team prefers to create code examples that show broad scenarios rather than individual API calls.

Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved. SPDX-License-Identifier: Apache-2.0