import Component from '@glimmer/component';
import { inject as service } from '@ember/service';
export default class SidebarStepComponent extends Component {
@service appointment
get isCurrentStep() {
return this.appointment.currentStepNum === this.args.stepNum;
}
}
@task(function* (cId, cptCode) {
let offices = yield this.store.query('office', {
filter: {
clinicianId: cId,
cptCodeId: cptCode
}
});
return offices;
}) fetchOfficeLocations;
// config/environment.js
let ENV = {
APP: {
...
clientPortalBaseURL: 'https://johnny-appleseed.clientsecure.me',
clinicianID: 2
}
};
- Should the widget respect the browser
back
button? - Should widget state be capture in the url:
/office-location/3866/date-time/4
? - Should widget state be capture in query parameters:
/&?cpt=3866&location=58763
? - Should the widget survive page reloads (2 or 3 could help mitigate)?
- Widget is currently coded to use dynamic segments to capture app state
- Like many side-bars, the semantic markup lies outside of the nested routes. We could use things like wormholes, but a service acting like a messaging bus is simpler (less vendor code / smaller bundle)
- Using Glimmer components are lighter and use native classes along with native getters to do
computed properties
. Tracked properties, or@tracked
are more ergonomic (no dependent key listing). Also most computed properties get little benefit from cached calculations and rolling your own is likely to suffice.
You will need the following things properly installed on your computer.
- Git
- Node.js (with npm)
- Ember CLI
- Google Chrome
This project uses Yarn and the resolution hash to make sure a particular package version is picked over another. It is suggested to have the latest version of Yarn installed.
git clone <repository-url>
this repositorycd simply-scheduling
yarn
ember serve
- Visit your app at http://localhost:4200.
- Visit your tests at http://localhost:4200/tests.
Make use of the many generators for code, try ember help generate
for more details
ember test
ember test --server
npm run lint:hbs
npm run lint:js
npm run lint:js -- --fix
ember build
(development)ember build --environment production
(production)
Specify what it takes to deploy your app.