Skip to content

Commit

Permalink
boiler plate code
Browse files Browse the repository at this point in the history
cedriclinares123 committed Dec 9, 2024

Verified

This commit was signed with the committer’s verified signature.
lucacome Luca Comellini
1 parent 09f9a29 commit 4126c01
Showing 3 changed files with 25 additions and 3 deletions.
6 changes: 6 additions & 0 deletions app/controllers/application.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
import Controller from '@ember/controller';
import { tracked } from '@glimmer/tracking';

export default class ApplicationController extends Controller {
@tracked taskList = ['Task 1', 'Task 2', 'Task 3'];
}
10 changes: 7 additions & 3 deletions app/templates/application.hbs
Original file line number Diff line number Diff line change
@@ -1,7 +1,11 @@
{{page-title "TodoList"}}

{{! The following component displays Ember's default welcome message. }}
<WelcomePage />
{{! Feel free to remove this! }}
<h1>Todo List</h1>

{{#each this.taskList as |task|}}
<div>
{{task}}
</div>
{{/each}}

{{outlet}}
12 changes: 12 additions & 0 deletions tests/unit/controllers/application-test.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
import { module, test } from 'qunit';
import { setupTest } from 'todo-list/tests/helpers';

module('Unit | Controller | application', function (hooks) {
setupTest(hooks);

// TODO: Replace this with your real tests.
test('it exists', function (assert) {
let controller = this.owner.lookup('controller:application');
assert.ok(controller);
});
});

0 comments on commit 4126c01

Please sign in to comment.