Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Uncaught TypeError: application.container.lookupFactory is not a function #3

Open
dmmfll opened this issue Aug 13, 2016 · 2 comments
Open

Comments

@dmmfll
Copy link

dmmfll commented Aug 13, 2016

Am new to ember so this error might be something I am missing.

I want to display a map in an ember app.

DEBUG: -------------------------------
ember.debug.js:6507DEBUG: Ember : 2.6.2
ember.debug.js:6507DEBUG: Ember Data : 2.7.0
ember.debug.js:6507DEBUG: jQuery : 2.2.4
ember.debug.js:6507DEBUG: -------------------------------

Steps to produce the error:

mapbox-gl.js:7 Uncaught TypeError: application.container.lookupFactory is not a function initialize @ mapbox-gl.js:7(anonymous function) @ ember.debug.js:5522(anonymous function) @ ember.debug.js:5538visit @ ember.debug.js:53955DAG.topsort @ ember.debug.js:2589_runInitializer @ ember.debug.js:5537runInstanceInitializers @ ember.debug.js:5520_bootSync @ ember.debug.js:3902didBecomeReady @ ember.debug.js:4914invoke @ ember.debug.js:991flush @ ember.debug.js:1055flush @ ember.debug.js:863end @ ember.debug.js:177run @ ember.debug.js:299join @ ember.debug.js:319run.join @ ember.debug.js:20614(anonymous function) @ ember.debug.js:20677fire @ jquery.js:3187fireWith @ jquery.js:3317ready @ jquery.js:3536completed @ jquery.js:3552

define('ember-cli-mapbox-gl/instance-initializers/mapbox-gl', ['exports'], function (exports) {
  'use strict';

  exports.initialize = initialize;

  function initialize(application) {
    var config = application.container.lookupFactory('config:environment');

    if (!config.mapbox || !config.mapbox.accessToken) {
      console.error('Please specify your mapbox.accessToken in your config.');
      return;
    }

    mapboxgl.accessToken = config.mapbox.accessToken;
  }

  exports['default'] = {
    name: 'mapbox-gl-access',
    initialize: initialize
  };
});

Tried Google searches for this error and found nothing that helped me resolve this issue so I am filing it here.

Thanks for your help.

@teejayhh
Copy link

I have the same issue!

@richardverheyen
Copy link

I also have the same issue

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants