From f16b15a798dccef11ac56541b2ab431eaeb0fa4f Mon Sep 17 00:00:00 2001 From: Chris LoPresto Date: Mon, 1 May 2017 04:14:36 -0400 Subject: [PATCH 1/2] Remove ember-truth-helpers dependency --- addon/helpers/equal.js | 3 ++ app/helpers/eq.js | 12 ++++++++ package.json | 1 - yarn.lock | 62 +++++++++++++++++++----------------------- 4 files changed, 43 insertions(+), 35 deletions(-) create mode 100644 addon/helpers/equal.js create mode 100644 app/helpers/eq.js diff --git a/addon/helpers/equal.js b/addon/helpers/equal.js new file mode 100644 index 00000000..8058f1d0 --- /dev/null +++ b/addon/helpers/equal.js @@ -0,0 +1,3 @@ +export function equalHelper(params) { + return params[0] === params[1]; +} diff --git a/app/helpers/eq.js b/app/helpers/eq.js new file mode 100644 index 00000000..f2069f1d --- /dev/null +++ b/app/helpers/eq.js @@ -0,0 +1,12 @@ +import Ember from 'ember'; +import { equalHelper } from 'ember-freestyle/helpers/equal'; + +let forExport = null; + +if (Ember.Helper) { + forExport = Ember.Helper.helper(equalHelper); +} else if (Ember.HTMLBars.makeBoundHelper) { + forExport = Ember.HTMLBars.makeBoundHelper(equalHelper); +} + +export default forExport; diff --git a/package.json b/package.json index 25547b17..6c696ada 100644 --- a/package.json +++ b/package.json @@ -30,7 +30,6 @@ "ember-cli-sass": "^6.1.3", "ember-remarkable": "3.6.1", "ember-runtime-enumerable-includes-polyfill": "^2.0.0", - "ember-truth-helpers": "^1.3.0", "es6-promise": "^4.1.0", "glob": "^7.1.1", "highlight.js": "^9.3.0" diff --git a/yarn.lock b/yarn.lock index 8fff9aef..070fe98d 100644 --- a/yarn.lock +++ b/yarn.lock @@ -2591,12 +2591,6 @@ ember-test-helpers@^0.6.3: version "0.6.3" resolved "https://registry.yarnpkg.com/ember-test-helpers/-/ember-test-helpers-0.6.3.tgz#f864cdf6f4e75f3f8768d6537785b5ab6e82d907" -ember-truth-helpers@^1.3.0: - version "1.3.0" - resolved "https://registry.yarnpkg.com/ember-truth-helpers/-/ember-truth-helpers-1.3.0.tgz#6ed9f83ce9a49f52bb416d55e227426339a64c60" - dependencies: - ember-cli-babel "^5.1.6" - ember-try-config@^2.0.1: version "2.1.0" resolved "https://registry.yarnpkg.com/ember-try-config/-/ember-try-config-2.1.0.tgz#e0e156229a542346a58ee6f6ad605104c98edfe0" @@ -5564,7 +5558,7 @@ read@1, read@~1.0.1, read@~1.0.7: dependencies: mute-stream "~0.0.4" -"readable-stream@1 || 2", readable-stream@^2, readable-stream@^2.0.2, readable-stream@^2.0.6, readable-stream@~2.0.5: +"readable-stream@1 || 2", readable-stream@^2, readable-stream@^2.0.1, readable-stream@^2.0.2, readable-stream@^2.0.6, readable-stream@~2.0.5: version "2.0.6" resolved "https://registry.yarnpkg.com/readable-stream/-/readable-stream-2.0.6.tgz#8f90341e68a53ccc928788dacfcd11b36eb9b78e" dependencies: @@ -5575,7 +5569,7 @@ read@1, read@~1.0.1, read@~1.0.7: string_decoder "~0.10.x" util-deprecate "~1.0.1" -"readable-stream@^2.0.0 || ^1.1.13", readable-stream@^2.0.1, readable-stream@^2.1.4, readable-stream@^2.2.2: +"readable-stream@^2.0.0 || ^1.1.13", readable-stream@^2.1.4, readable-stream@^2.2.2: version "2.2.9" resolved "https://registry.yarnpkg.com/readable-stream/-/readable-stream-2.2.9.tgz#cf78ec6f4a6d1eb43d26488cac97f042e74b7fc8" dependencies: @@ -5752,32 +5746,7 @@ repeating@^2.0.0: dependencies: is-finite "^1.0.0" -request@2, request@^2.47.0, request@~2.67.0: - version "2.67.0" - resolved "https://registry.yarnpkg.com/request/-/request-2.67.0.tgz#8af74780e2bf11ea0ae9aa965c11f11afd272742" - dependencies: - aws-sign2 "~0.6.0" - bl "~1.0.0" - caseless "~0.11.0" - combined-stream "~1.0.5" - extend "~3.0.0" - forever-agent "~0.6.1" - form-data "~1.0.0-rc3" - har-validator "~2.0.2" - hawk "~3.1.0" - http-signature "~1.1.0" - is-typedarray "~1.0.0" - isstream "~0.1.2" - json-stringify-safe "~5.0.1" - mime-types "~2.1.7" - node-uuid "~1.4.7" - oauth-sign "~0.8.0" - qs "~5.2.0" - stringstream "~0.0.4" - tough-cookie "~2.2.0" - tunnel-agent "~0.4.1" - -request@^2.79.0, request@^2.81.0: +request@2, request@^2.47.0, request@^2.79.0, request@^2.81.0: version "2.81.0" resolved "https://registry.yarnpkg.com/request/-/request-2.81.0.tgz#c6928946a0e06c5f8d6f8a9333469ffda46298a0" dependencies: @@ -5804,6 +5773,31 @@ request@^2.79.0, request@^2.81.0: tunnel-agent "^0.6.0" uuid "^3.0.0" +request@~2.67.0: + version "2.67.0" + resolved "https://registry.yarnpkg.com/request/-/request-2.67.0.tgz#8af74780e2bf11ea0ae9aa965c11f11afd272742" + dependencies: + aws-sign2 "~0.6.0" + bl "~1.0.0" + caseless "~0.11.0" + combined-stream "~1.0.5" + extend "~3.0.0" + forever-agent "~0.6.1" + form-data "~1.0.0-rc3" + har-validator "~2.0.2" + hawk "~3.1.0" + http-signature "~1.1.0" + is-typedarray "~1.0.0" + isstream "~0.1.2" + json-stringify-safe "~5.0.1" + mime-types "~2.1.7" + node-uuid "~1.4.7" + oauth-sign "~0.8.0" + qs "~5.2.0" + stringstream "~0.0.4" + tough-cookie "~2.2.0" + tunnel-agent "~0.4.1" + require-dir@^0.3.0: version "0.3.1" resolved "https://registry.yarnpkg.com/require-dir/-/require-dir-0.3.1.tgz#b5a8e28bae0343bb0d0cc38ab1f531e1931b264a" From f8eb499561f7fb2866a97fb37c34e6f611669a46 Mon Sep 17 00:00:00 2001 From: Chris LoPresto Date: Tue, 2 May 2017 21:57:32 -0400 Subject: [PATCH 2/2] Rename to variant-eq helper to avoid ember-truth-helper collisions --- addon/templates/components/freestyle-variant-list.hbs | 2 +- app/helpers/{eq.js => variant-eq.js} | 0 2 files changed, 1 insertion(+), 1 deletion(-) rename app/helpers/{eq.js => variant-eq.js} (100%) diff --git a/addon/templates/components/freestyle-variant-list.hbs b/addon/templates/components/freestyle-variant-list.hbs index c2d0370e..f281767a 100644 --- a/addon/templates/components/freestyle-variant-list.hbs +++ b/addon/templates/components/freestyle-variant-list.hbs @@ -1,7 +1,7 @@