How to implement logging mechanism for React.js application on AWS CloudWatch

Viewed 621

I have a React.js app that is deployed with AWS Amplify. What I want is to log errors and etc. to CloudWatch, however, after researching on the internet, I couldn't find a proper way to do it so.

I have tried the Amplify SDK and used a utility called Logger

However, it seems like this utility only helps to log things in the browser console, rather than logging it to the Access Logs that is coming with Amplify. What is the most convenient way to log things in such a scenario? Thanks.

0 Answers
Related