File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -7,5 +7,5 @@ export default class Router extends EmberRouter {
77}
88
99Router . map ( function ( ) {
10- // Add route declarations here
10+ this . route ( 'quiz' ) ;
1111} ) ;
Original file line number Diff line number Diff line change 1+ import Route from '@ember/routing/route' ;
2+
3+ export default class IndexRoute extends Route { }
Original file line number Diff line number Diff line change 1+ import Route from '@ember/routing/route' ;
2+
3+ export default class QuizRoute extends Route { }
Original file line number Diff line number Diff line change 11import { pageTitle } from ' ember-page-title' ;
2- import { WelcomePage } from ' ember-welcome-page' ;
32
43<template >
5- {{pageTitle " EmberLatest " }}
4+ {{pageTitle " Assignment " }}
65
76 {{ outlet }}
8-
9- {{! The following component displays Ember's default welcome message. }}
10- <WelcomePage />
11- {{! Feel free to remove this! }}
127</template >
Original file line number Diff line number Diff line change 1+ import type { TOC } from ' @ember/component/template-only' ;
2+ import { pageTitle } from ' ember-page-title' ;
3+ import { LinkTo } from ' @ember/routing' ;
4+
5+ interface IndexSignature {
6+ Args: {
7+ model: unknown ;
8+ controller: unknown ;
9+ };
10+ }
11+
12+ <template >
13+ {{pageTitle " Index" }}
14+
15+ <LinkTo @ route =" quiz" >Quiz</LinkTo >
16+ </template > satisfies TOC <IndexSignature >;
Original file line number Diff line number Diff line change 1+ import type { TOC } from ' @ember/component/template-only' ;
2+ import { pageTitle } from ' ember-page-title' ;
3+
4+ interface QuizSignature {
5+ Args: {
6+ model: unknown ;
7+ controller: unknown ;
8+ };
9+ }
10+
11+ <template >{{pageTitle " Quiz" }} </template > satisfies TOC <QuizSignature >;
Original file line number Diff line number Diff line change 1+ import { module , test } from 'qunit' ;
2+ import { setupTest } from 'ember-latest/tests/helpers' ;
3+
4+ module ( 'Unit | Route | index' , function ( hooks ) {
5+ setupTest ( hooks ) ;
6+
7+ test ( 'it exists' , function ( assert ) {
8+ let route = this . owner . lookup ( 'route:index' ) ;
9+ assert . ok ( route ) ;
10+ } ) ;
11+ } ) ;
Original file line number Diff line number Diff line change 1+ import { module , test } from 'qunit' ;
2+ import { setupTest } from 'ember-latest/tests/helpers' ;
3+
4+ module ( 'Unit | Route | quiz' , function ( hooks ) {
5+ setupTest ( hooks ) ;
6+
7+ test ( 'it exists' , function ( assert ) {
8+ let route = this . owner . lookup ( 'route:quiz' ) ;
9+ assert . ok ( route ) ;
10+ } ) ;
11+ } ) ;
You can’t perform that action at this time.
0 commit comments