mardi 22 septembre 2015

Ember 2.0 with Ember-CLI, how to access 'document.location.host'?

Putting following line e.g. in app/controllers/application.js

console.log(document.location.host);

will not work, as the browser-context is not present. What is the alternative? It should also work with other javascript objects.




Aucun commentaire:

Enregistrer un commentaire