Skip to content

Commit

Permalink
update controllers syntax (#1117)
Browse files Browse the repository at this point in the history
* update controllers syntax

* remove unused reexport
  • Loading branch information
miguelcobain authored Feb 8, 2022
1 parent d1c6b25 commit 2f2b468
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 21 deletions.
13 changes: 0 additions & 13 deletions addon/controllers/docs/api/class.js

This file was deleted.

1 change: 0 additions & 1 deletion app/controllers/docs/api/class.js

This file was deleted.

Original file line number Diff line number Diff line change
@@ -1,11 +1,10 @@
import Controller from '@ember/controller';
import { computed } from '@ember/object';
import compileMarkdown from 'ember-cli-addon-docs/utils/compile-markdown';
import { htmlSafe } from '@ember/template';

export default Controller.extend({
export default class RouteUsingCompileMarkdown extends Controller {

body: `In the beginning, we could only use
body = `In the beginning, we could only use
\`\`\`js
function foo() {
Expand All @@ -20,10 +19,10 @@ const foo = () => {
console.log('bar');
});
\`\`\`
`,
`;

htmlBody: computed('body', function() {
get htmlBody() {
return htmlSafe(compileMarkdown(this.body));
})
}

});
}

0 comments on commit 2f2b468

Please sign in to comment.