Skip to content

Commit 21b4b60

Browse files
committed
Upgrade Ember to 3.26
1 parent 2c8acf7 commit 21b4b60

Some content is hidden

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

52 files changed

+12249
-510
lines changed

.editorconfig

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,6 @@
44

55
root = true
66

7-
87
[*]
98
end_of_line = lf
109
charset = utf-8

.eslintignore

Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,21 @@
1+
# unconventional js
2+
/blueprints/*/files/
3+
/vendor/
4+
5+
# compiled output
6+
/dist/
7+
/tmp/
8+
9+
# dependencies
10+
/bower_components/
11+
/node_modules/
12+
13+
# misc
14+
/coverage/
15+
!.*
16+
.eslintcache
17+
18+
# ember-try
19+
/.node_modules.ember-try/
20+
/bower.json.ember-try
21+
/package.json.ember-try

.eslintrc.js

Lines changed: 44 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,16 +1,54 @@
1+
'use strict';
2+
13
module.exports = {
24
root: true,
5+
parser: 'babel-eslint',
36
parserOptions: {
4-
ecmaVersion: 2017,
5-
sourceType: 'module'
7+
ecmaVersion: 2018,
8+
sourceType: 'module',
9+
ecmaFeatures: {
10+
legacyDecorators: true,
11+
},
612
},
13+
plugins: ['ember'],
714
extends: [
815
'eslint:recommended',
9-
'plugin:ember-suave/recommended'
16+
'plugin:ember/recommended',
17+
'plugin:prettier/recommended',
1018
],
1119
env: {
12-
browser: true
20+
browser: true,
1321
},
14-
rules: {
15-
}
22+
rules: {},
23+
overrides: [
24+
// node files
25+
{
26+
files: [
27+
'.eslintrc.js',
28+
'.prettierrc.js',
29+
'.template-lintrc.js',
30+
'ember-cli-build.js',
31+
'index.js',
32+
'testem.js',
33+
'blueprints/*/index.js',
34+
'config/**/*.js',
35+
'tests/dummy/config/**/*.js',
36+
],
37+
excludedFiles: [
38+
'addon/**',
39+
'addon-test-support/**',
40+
'app/**',
41+
'tests/dummy/app/**',
42+
],
43+
parserOptions: {
44+
sourceType: 'script',
45+
},
46+
env: {
47+
browser: false,
48+
node: true,
49+
},
50+
plugins: ['node'],
51+
extends: ['plugin:node/recommended'],
52+
},
53+
],
1654
};

.gitignore

Lines changed: 14 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -1,23 +1,26 @@
11
# See https://help.github.com/ignore-files/ for more about ignoring files.
22

33
# compiled output
4-
/dist
5-
/tmp
4+
/dist/
5+
/tmp/
66

77
# dependencies
8-
/node_modules
9-
/bower_components
8+
/bower_components/
9+
/node_modules/
1010

1111
# misc
12+
/.env*
13+
/.pnp*
1214
/.sass-cache
15+
/.eslintcache
1316
/connect.lock
14-
/coverage/*
17+
/coverage/
1518
/libpeerconnection.log
16-
npm-debug.log*
17-
yarn-error.log
18-
testem.log
19+
/npm-debug.log*
20+
/testem.log
21+
/yarn-error.log
1922

2023
# ember-try
21-
.node_modules.ember-try/
22-
bower.json.ember-try
23-
package.json.ember-try
24+
/.node_modules.ember-try/
25+
/bower.json.ember-try
26+
/package.json.ember-try

.npmignore

Lines changed: 34 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -1,16 +1,35 @@
1-
/bower_components
1+
# compiled output
2+
/dist/
3+
/tmp/
4+
5+
# dependencies
6+
/bower_components/
7+
8+
# misc
9+
/.bowerrc
10+
/.editorconfig
11+
/.ember-cli
12+
/.env*
13+
/.eslintcache
14+
/.eslintignore
15+
/.eslintrc.js
16+
/.git/
17+
/.gitignore
18+
/.prettierignore
19+
/.prettierrc.js
20+
/.template-lintrc.js
21+
/.travis.yml
22+
/.watchmanconfig
23+
/bower.json
224
/config/ember-try.js
3-
/dist
4-
/tests
5-
/tmp
6-
**/.gitkeep
7-
.bowerrc
8-
.editorconfig
9-
.ember-cli
10-
.gitignore
11-
.eslintrc.js
12-
.watchmanconfig
13-
.travis.yml
14-
bower.json
15-
ember-cli-build.js
16-
testem.js
25+
/CONTRIBUTING.md
26+
/ember-cli-build.js
27+
/testem.js
28+
/tests/
29+
/yarn.lock
30+
.gitkeep
31+
32+
# ember-try
33+
/.node_modules.ember-try/
34+
/bower.json.ember-try
35+
/package.json.ember-try

.prettierignore

Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,21 @@
1+
# unconventional js
2+
/blueprints/*/files/
3+
/vendor/
4+
5+
# compiled output
6+
/dist/
7+
/tmp/
8+
9+
# dependencies
10+
/bower_components/
11+
/node_modules/
12+
13+
# misc
14+
/coverage/
15+
!.*
16+
.eslintcache
17+
18+
# ember-try
19+
/.node_modules.ember-try/
20+
/bower.json.ember-try
21+
/package.json.ember-try

.prettierrc.js

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
'use strict';
2+
3+
module.exports = {
4+
singleQuote: true,
5+
};

.template-lintrc.js

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
'use strict';
2+
3+
module.exports = {
4+
extends: 'octane',
5+
};

.travis.yml

Lines changed: 43 additions & 24 deletions
Original file line numberDiff line numberDiff line change
@@ -1,45 +1,64 @@
11
---
22
language: node_js
33
node_js:
4-
- "6"
4+
# we recommend testing addons with the same minimum supported node version as Ember CLI
5+
# so that your addon works for all apps
6+
- "10"
57

6-
sudo: false
7-
dist: trusty
8+
dist: xenial
89

910
addons:
1011
chrome: stable
1112

1213
cache:
13-
directories:
14-
- $HOME/.npm
14+
yarn: true
1515

1616
env:
1717
global:
1818
# See https://git.io/vdao3 for details.
1919
- JOBS=1
20-
matrix:
21-
- EMBER_TRY_SCENARIO=ember-lts-2.8
22-
- EMBER_TRY_SCENARIO=ember-lts-2.12
23-
- EMBER_TRY_SCENARIO=ember-lts-2.16
24-
- EMBER_TRY_SCENARIO=ember-lts-2.18
25-
- EMBER_TRY_SCENARIO=ember-lts-3.4
26-
- EMBER_TRY_SCENARIO=ember-release
27-
- EMBER_TRY_SCENARIO=ember-beta
28-
- EMBER_TRY_SCENARIO=ember-canary
29-
- EMBER_TRY_SCENARIO=ember-default
30-
- EMBER_TRY_SCENARIO=ember-default-with-jquery
31-
32-
matrix:
20+
21+
branches:
22+
only:
23+
- master
24+
# npm version tags
25+
- /^v\d+\.\d+\.\d+/
26+
27+
jobs:
3328
fast_finish: true
3429
allow_failures:
3530
- env: EMBER_TRY_SCENARIO=ember-canary
3631

32+
include:
33+
# runs linting and tests with current locked deps
34+
- stage: "Tests"
35+
name: "Tests"
36+
script:
37+
- yarn lint
38+
- yarn test:ember
39+
40+
- stage: "Additional Tests"
41+
name: "Floating Dependencies"
42+
install:
43+
- yarn install --no-lockfile --non-interactive
44+
script:
45+
- yarn test:ember
46+
47+
# we recommend new addons test the current and previous LTS
48+
# as well as latest stable release (bonus points to beta/canary)
49+
- env: EMBER_TRY_SCENARIO=ember-lts-3.16
50+
- env: EMBER_TRY_SCENARIO=ember-lts-3.20
51+
- env: EMBER_TRY_SCENARIO=ember-release
52+
- env: EMBER_TRY_SCENARIO=ember-beta
53+
- env: EMBER_TRY_SCENARIO=ember-canary
54+
- env: EMBER_TRY_SCENARIO=ember-default-with-jquery
55+
- env: EMBER_TRY_SCENARIO=ember-classic
56+
- env: EMBER_TRY_SCENARIO=embroider-safe
57+
- env: EMBER_TRY_SCENARIO=embroider-optimized
58+
3759
before_install:
38-
- npm config set spin false
39-
- npm install -g npm@4
40-
- npm --version
60+
- curl -o- -L https://yarnpkg.com/install.sh | bash
61+
- export PATH=$HOME/.yarn/bin:$PATH
4162

4263
script:
43-
# Usually, it's ok to finish the test scenario without reverting
44-
# to the addon's original dependency state, skipping "cleanup".
45-
- node_modules/.bin/ember try:one $EMBER_TRY_SCENARIO --skip-cleanup
64+
- node_modules/.bin/ember try:one $EMBER_TRY_SCENARIO

addon/components/radio-button-input.js

Lines changed: 10 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -33,15 +33,15 @@ export default Component.extend({
3333
'value',
3434
'ariaLabelledby:aria-labelledby',
3535
'ariaDescribedby:aria-describedby',
36-
'checkedStr:aria-checked'
36+
'checkedStr:aria-checked',
3737
],
3838

39-
checked: computed('groupValue', 'value', function() {
40-
return isEqual(this.get('groupValue'), this.get('value'));
39+
checked: computed('groupValue', 'value', function () {
40+
return isEqual(this.groupValue, this.value);
4141
}).readOnly(),
4242

43-
checkedStr: computed('checked', function() {
44-
let checked = this.get('checked');
43+
checkedStr: computed('checked', function () {
44+
let checked = this.checked;
4545

4646
if (typeof checked === 'boolean') {
4747
return checked.toString();
@@ -51,8 +51,8 @@ export default Component.extend({
5151
}),
5252

5353
invokeChangedAction() {
54-
let value = this.get('value');
55-
let changedAction = this.get('changed');
54+
let value = this.value;
55+
let changedAction = this.changed;
5656

5757
if (typeof changedAction === 'string') {
5858
this.sendAction('changed', value);
@@ -65,12 +65,12 @@ export default Component.extend({
6565
},
6666

6767
change() {
68-
let value = this.get('value');
69-
let groupValue = this.get('groupValue');
68+
let value = this.value;
69+
let groupValue = this.groupValue;
7070

7171
if (groupValue !== value) {
7272
this.set('groupValue', value);
7373
run.once(this, 'invokeChangedAction');
7474
}
75-
}
75+
},
7676
});

0 commit comments

Comments
 (0)