# Javascript APM for collecting frontend metrics

**URL:** <https://discuss.elastic.co/t/javascript-apm-for-collecting-frontend-metrics/238978>\
**Category:** APM\
**Tags:** rum\
**Created:** [June 27, 2020, 10:33pm UTC](https://discuss.elastic.co/t/javascript-apm-for-collecting-frontend-metrics/238978 "2020-06-27T22:33:46Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![alixander](https://avatars.discourse-cdn.com/v4/letter/a/e495f1/32.png) [@alixander](https://discuss.elastic.co/u/alixander)\
**Post date:** [June 27, 2020, 10:33pm UTC](https://discuss.elastic.co/t/javascript-apm-for-collecting-frontend-metrics/238978/1 "2020-06-27T22:33:46Z")

</div>

Hi, I'm trying to collect metrics on the frontend like increment a metric whenever a user performs an action. My question is this: is the rum-agent meant for this use case or is there something more suitable? The reason I ask is because the example and API make it seem like Transaction is only for measuring time. If I were to collect metrics this way, I think I would just start the transaction, add the appropriate tags, and then end it right away.

---

<div class="post-metadata">

**Author:** ![system](https://us1.discourse-cdn.com/elastic/original/3X/1/a/1ac57faf039f6b580b3f104ef42a2a89e41014de.png) [@system](https://discuss.elastic.co/u/system)\
**Post date:** [July 18, 2020, 6:33pm UTC](https://discuss.elastic.co/t/javascript-apm-for-collecting-frontend-metrics/238978/2 "2020-07-18T18:33:57Z")

</div>

This topic was automatically closed 20 days after the last reply. New replies are no longer allowed.
