[elevio] analytics.ready is called before window._elev is actually initialized.

Open
#325 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Assessment

Difficulty
3/5
Estimated time
1-2 days
Newbie friendliness
30/100
Issue type
Bug
Clarity
Mostly clear
Activity status
Stale
Tech stack
javascript
Domain
analytics

Research direction

Start by locating the Elev.io integration entry point and the code that calls analytics.ready. Trace when window._elev and its on(event, callback) handler become available; done means consumers can use Elev.io after analytics.ready without polling for initialization.

Written by the indexing model from the issue text.

Description

Migrated from #14 by @iand675

Elev.io appears to initialize things in several stages, but the key thing is that analytics.ready is called before window._elev.on(event, callback) is set on window._elev. Consequently, it's rather difficult to do much with elev.io aside from setting up some kind of loop that polls for window._elev to actually be ready for use.

Dominant language
JavaScript
Stars
125
Forks
136
Avg merge
2h 45m
Merged PRs (30d)
1

Contributor guide

No contributing guide indexed for this repository

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

More from segmentio/analytics.js-integrations

All issues in segmentio/analytics.js-integrations

Similar issues

More JavaScript issues

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.