Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

ember-cli-document-title

Package Overview
Dependencies
Maintainers
3
Versions
12
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

ember-cli-document-title - npm Package Compare versions

Comparing version 0.4.0 to 1.0.0

fastboot-tests/fixtures/fastboot/app/index.html

56

package.json
{
"name": "ember-cli-document-title",
"version": "0.4.0",
"version": "1.0.0",
"description": "Adding document title functionality to your ember app",

@@ -25,34 +25,42 @@ "keywords": [

"build": "ember build",
"lint:js": "eslint ./*.js addon addon-test-support app config lib server test-support tests fastboot-tests",
"lint:hbs": "ember-template-lint .",
"lint:js": "eslint .",
"start": "ember serve",
"test": "ember try:each && ember fastboot:test"
"test": "ember test && ember fastboot:test",
"test:all": "ember try:each"
},
"dependencies": {
"ember-cli-babel": "^6.6.0"
"ember-cli-babel": "^6.16.0"
},
"devDependencies": {
"broccoli-asset-rev": "^2.4.5",
"@ember/optional-features": "^0.6.3",
"broccoli-asset-rev": "^2.7.0",
"chai": "^4.1.2",
"ember-cli": "~2.18.0",
"ember-cli-dependency-checker": "^2.0.0",
"ember-cli-eslint": "^4.2.1",
"ember-cli-htmlbars": "^2.0.1",
"ember-cli-htmlbars-inline-precompile": "^1.0.0",
"ember-cli-inject-live-reload": "^1.4.1",
"ember-cli-qunit": "^4.1.1",
"ember-cli-shims": "^1.2.0",
"ember-cli-sri": "^2.1.0",
"ember-cli-uglify": "^2.0.0",
"ember-disable-prototype-extensions": "^1.1.2",
"ember-ajax": "^3.1.0",
"ember-cli": "~3.6.0-beta.1",
"ember-cli-dependency-checker": "^3.0.0",
"ember-cli-eslint": "^4.2.3",
"ember-cli-htmlbars": "^3.0.0",
"ember-cli-htmlbars-inline-precompile": "^1.0.3",
"ember-cli-inject-live-reload": "^1.8.2",
"ember-cli-sri": "^2.1.1",
"ember-cli-template-lint": "^1.0.0-beta.1",
"ember-cli-uglify": "^2.1.0",
"ember-disable-prototype-extensions": "^1.1.3",
"ember-export-application-global": "^2.0.0",
"ember-fastboot-addon-tests": "^0.4.0",
"ember-load-initializers": "^1.0.0",
"ember-resolver": "^4.0.0",
"ember-source": "~2.18.0",
"eslint-plugin-ember": "^5.0.0",
"eslint-plugin-node": "^5.2.1",
"loader.js": "^4.2.3"
"ember-fastboot-addon-tests": "^0.5.0",
"ember-load-initializers": "^1.1.0",
"ember-maybe-import-regenerator": "^0.1.6",
"ember-qunit": "^3.4.1",
"ember-resolver": "^5.0.1",
"ember-source": "~3.6.0-beta.4",
"ember-source-channel-url": "^1.1.0",
"ember-try": "^1.0.0",
"eslint-plugin-ember": "^5.2.0",
"eslint-plugin-node": "^7.0.1",
"loader.js": "^4.7.0",
"qunit-dom": "^0.8.0"
},
"engines": {
"node": "^4.5 || 6.* || >= 7.*"
"node": "6.* || 8.* || >= 10.*"
},

@@ -59,0 +67,0 @@ "ember-addon": {

@@ -16,3 +16,3 @@ var get = Ember.get;

// defined.
title: null
title: null,
};

@@ -61,20 +61,21 @@

var completion = Promise.resolve()
.then(function() {
if (typeof title === 'function') {
// Wait for all tokens to resolve. It resolves immediately if all tokens are plain values (not promises).
return Promise.all(tokens)
.then(function(resolvedTokens) {
.then(function() {
if (typeof title === 'function') {
// Wait for all tokens to resolve. It resolves immediately if all tokens are plain values (not promises).
return Promise.all(tokens).then(function(resolvedTokens) {
return title.call(self, resolvedTokens);
});
} else {
// Tokens aren't even considered... a string
// title just sledgehammer overwrites any children tokens.
return title;
}
})
.then(function(finalTitle) {
// Stubbable fn that sets document.title
self.router.setTitle(finalTitle);
});
} else {
// Tokens aren't even considered... a string
// title just sledgehammer overwrites any children tokens.
return title;
}
})
.then(function(finalTitle) {
let router = getOwner(self).lookup('router:main');
// Stubbable fn that sets document.title
router.setTitle(finalTitle);
});
// Tell FastBoot about our async code

@@ -85,3 +86,2 @@ var fastboot = lookupFastBoot(this);

}
} else {

@@ -91,3 +91,3 @@ // Continue bubbling.

}
}
},
};

@@ -115,3 +115,3 @@

}
}
},
});

@@ -118,0 +118,0 @@

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc