Skip to content

Commit cf2d4be

Browse files
authored
Merge branch 'gjs' into gjs-routing
2 parents 9517054 + 2a11756 commit cf2d4be

File tree

478 files changed

+53127
-2449
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

478 files changed

+53127
-2449
lines changed

.local.dic

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -252,3 +252,4 @@ websocket
252252
working-with-html-css-and-javascript
253253
yay
254254
ZEIT
255+
userQuestion

.stylelintignore

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,7 @@
44
# compiled output
55
/dist/
66
/public/assets
7+
/public/downloads
78

89
# addons
910
/.node_modules.ember-try/

guides/release/accessibility/page-template-considerations.md

Lines changed: 19 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -17,29 +17,32 @@ Consider this format:
1717

1818
Note that the unique page title is first. This is because it is the most important piece of information from a contextual perspective. Since a user with a screen reader can interrupt the screen reader as they wish, it introduces less fatigue when the unique page title is first, but provides the additional guidance if it is desired.
1919

20-
A simple way to add page titles is to use the `page-title` helper which comes from the [ember-page-title](https://github.com/ember-cli/ember-page-title) addon that is installed by default in new apps. We can use this helper to set the page title at any point in any template.
20+
A simple way to add page titles is to use the `pageTitle` helper which comes from the [ember-page-title](https://github.com/ember-cli/ember-page-title) addon that is installed by default in new apps. We can use this helper to set the page title at any point in any template.
2121

2222
For example, if we have a “posts” route, we can set the page title for it like so:
2323

24+
```gjs {data-filename=app/routes/posts.gjs}
25+
import { pageTitle } from 'ember-page-title';
2426
25-
```handlebars {data-filename=app/routes/posts.hbs}
26-
{{page-title "Posts - Site Title"}}
27-
28-
{{outlet}}
27+
<template>
28+
{{pageTitle "Posts"}}
29+
{{outlet}}
30+
</template>
2931
```
3032

3133
Extending the example, if we have a “post” route that lives within the “posts” route, we could set its page title like so:
3234

33-
```handlebars {data-filename=app/routes/posts/post.hbs}
34-
{{page-title (concat @model.title " - Site Title")}}
35+
```gjs {data-filename=app/routes/posts/post.gjs}
36+
import { pageTitle } from 'ember-page-title';
3537
36-
<h1>{{@model.title}}</h1>
37-
```
38+
<template>
39+
{{pageTitle @model.title}} {{! e.g., "My Title" }}
3840
39-
When your needs become more complex, the following addons facilitate page titles in a more dynamic and maintainable way.
41+
<h1>{{@model.title}}</h1>
42+
</template>
43+
```
4044

41-
- [ember-cli-head](https://github.com/ronco/ember-cli-head)
42-
- [ember-cli-document-title](https://github.com/kimroen/ember-cli-document-title)
45+
Each call to the `{{pageTitle}}` helper will prepend the title string to the existing title all the way up to the root title in `application.gts`. So, if your application is titled "My App", then the full title for the above example would be "My Title | Posts | My App".
4346

4447
To evaluate more addons to add/manage content in the `<head>` of a page, view this category on [Ember Observer](https://emberobserver.com/categories/header-content).
4548

@@ -48,14 +51,14 @@ You can test that page titles are generated correctly by asserting on the value
4851
```javascript {data-filename=tests/acceptance/posts-test.js}
4952
import { module, test } from 'qunit';
5053
import { visit, currentURL } from '@ember/test-helpers';
51-
import { setupApplicationTest } from 'my-app-name/tests/helpers';
54+
import { setupApplicationTest } from 'my-app/tests/helpers';
5255

53-
module('Acceptance | posts', function(hooks) {
56+
module('Acceptance | posts', function (hooks) {
5457
setupApplicationTest(hooks);
5558

56-
test('visiting /posts', async function(assert) {
59+
test('visiting /posts', async function (assert) {
5760
await visit('/posts');
58-
assert.equal(document.title, 'Posts - Site Title');
61+
assert.equal(document.title, 'Posts | My App');
5962
});
6063
});
6164
```

guides/release/code-editors/index.md

Lines changed: 0 additions & 22 deletions
Original file line numberDiff line numberDiff line change
@@ -102,22 +102,6 @@ Shortcuts to navigate related files with Ember.js projects.
102102
[Ember Tools](https://github.com/AndrewRadev/ember_tools.vim) -
103103
Various tools for working with Ember.js projects.
104104

105-
## Atom
106-
107-
Atom is hackable text editor for the 21st Century.
108-
109-
[atom-ide-ember](https://github.com/josa42/atom-ide-ember) -
110-
Atom package to use the Ember Language Server.
111-
112-
[emberjs-atom](https://atom.io/packages/emberjs-atom) -
113-
Atom autocomplete and snippets for Ember.js.
114-
115-
[atom-ember-snippets](https://github.com/mattmcmanus/atom-ember-snippets) -
116-
Ember.js ES6, EmberData & Handlebars snippets for Atom editor.
117-
118-
[language-ember-htmlbars](https://atom.io/packages/language-ember-htmlbars) -
119-
Add Ember template syntax highlighting and indentation to Atom
120-
121105
## Sublime Text
122106

123107
A sophisticated text editor for code, markup and prose.
@@ -127,9 +111,3 @@ Ember CLI snippets for Sublime Text 3.
127111

128112
[ember-component-template-split-view](https://github.com/mmitchellgarcia/ember-component-template-split-view) -
129113
Super simple Sublime Text plugin that will let you open corresponding template or route files with Ember.js components.
130-
131-
## CodeLobster IDE
132-
133-
CodeLobster IDE is a smart free cross-platform editor.
134-
135-
[CodeLobster IDE plug-in for Ember](http://www.codelobster.com/emberjs.html) gives autocomplete and tooltips for Ember.js functions, context and dynamic help.

0 commit comments

Comments
 (0)