aurelia-navigation

Using SASS with Aurelia's Skeleton Navigation project

谁都会走 提交于 2019-12-04 12:36:52
问题 var gulp = require('gulp'); var sass = require('gulp-sass'); var runSequence = require('run-sequence'); var changed = require('gulp-changed'); var plumber = require('gulp-plumber'); var to5 = require('gulp-babel'); var sourcemaps = require('gulp-sourcemaps'); var paths = require('../paths'); var compilerOptions = require('../babel-options'); var assign = Object.assign || require('object.assign'); // transpiles changed es6 files to SystemJS format // the plumber() call prevents 'pipe breaking'

Using SASS with Aurelia's Skeleton Navigation project

馋奶兔 提交于 2019-12-03 08:14:18
var gulp = require('gulp'); var sass = require('gulp-sass'); var runSequence = require('run-sequence'); var changed = require('gulp-changed'); var plumber = require('gulp-plumber'); var to5 = require('gulp-babel'); var sourcemaps = require('gulp-sourcemaps'); var paths = require('../paths'); var compilerOptions = require('../babel-options'); var assign = Object.assign || require('object.assign'); // transpiles changed es6 files to SystemJS format // the plumber() call prevents 'pipe breaking' caused // by errors from other gulp plugins // https://www.npmjs.com/package/gulp-plumber gulp.task(

Reload current page in Aurelia

时光毁灭记忆、已成空白 提交于 2019-11-30 17:22:28
I have an Aurelia application where the user can select the company they're currently "working on". Every page in the app is dependent on the currently selected company, and the user can select a new company from a drop-down menu. The drop-down is a component sitting on the nav-bar. What I'd like is to have that component reload the current page on the change.delegate handler without restarting the app. So setting window.location.href is out of the question. Is there a way to force the aurelia Router to reload the current route/page? The alternative would be to use the EventAggregator to

Aurelia: During a Router's Pipeline Step, how do I bind a variable to that router?

蓝咒 提交于 2019-11-29 07:20:28
I'd like to pass the user, found during the AuthorizeStep to either the App class and then to the home module . Here's what I have: export class App { configureRouter(config, router) { config.addPipelineStep('authorize', AuthorizeStep); config.map([ {route: ['', ':filter'], name: "", moduleId: 'welcome'} {route: 'home', name: "home", moduleId: 'home' auth:true} ]); this.router = router; } } class AuthorizeStep { run(routingContext, next) { if (routingContext.nextInstructions.some(i => i.config.auth)) { this.client.get('auth/login') .then(response => { this.user = response.content; }); } return

Aurelia: During a Router's Pipeline Step, how do I bind a variable to that router?

社会主义新天地 提交于 2019-11-28 00:58:10
问题 I'd like to pass the user, found during the AuthorizeStep to either the App class and then to the home module . Here's what I have: export class App { configureRouter(config, router) { config.addPipelineStep('authorize', AuthorizeStep); config.map([ {route: ['', ':filter'], name: "", moduleId: 'welcome'} {route: 'home', name: "home", moduleId: 'home' auth:true} ]); this.router = router; } } class AuthorizeStep { run(routingContext, next) { if (routingContext.nextInstructions.some(i => i

How to switch between login page and app with Aurelia

余生长醉 提交于 2019-11-26 22:54:10
问题 I'm using the Aurelia skeleton for my project. Everything seemed so intuitive, however I'm stuck with a problem which I suspect is fairly easy (if you know how). The problem is that the app.html / app.js is initially showing a nav bar and loading some default styles. Now I need a login page, which does not load anything but its own styles, no navbar no nothing - just its own login form. So I tried something like this: app.js <template> <div if.bind="auth.isNotAuthenticated()"> <require from=