Sha256: 5bb45f183b1717b5540152773a861ee8d09818c85f2219cc85f6591b7627c588
Contents?: true
Size: 567 Bytes
Versions: 2
Compression:
Stored size: 567 Bytes
Contents
/** @module ember */ import { get } from 'ember-metal'; /** Returns the currently active route name. Example: ```javascript function validateRouteName() { equal(currentRouteName(), 'some.path', "correct route was transitioned into."); } visit('/some/path').then(validateRouteName) ``` @method currentRouteName @return {Object} The name of the currently active route. @since 1.5.0 @public */ export default function currentRouteName(app) { let routingService = app.__container__.lookup('service:-routing'); return get(routingService, 'currentRouteName'); }
Version data entries
2 entries across 2 versions & 1 rubygems
Version | Path |
---|---|
discourse-ember-source-3.5.1.1 | dist/es/ember-testing/lib/helpers/current_route_name.js |
discourse-ember-source-3.5.1.0 | dist/dist/es/ember-testing/lib/helpers/current_route_name.js |