Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Remove ember-truth-helpers dependency #112

Merged
merged 2 commits into from
May 3, 2017
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 3 additions & 0 deletions addon/helpers/equal.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
export function equalHelper(params) {
return params[0] === params[1];
}
12 changes: 12 additions & 0 deletions app/helpers/eq.js
Original file line number Diff line number Diff line change
@@ -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;
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This implementation will conflict with an implementation from ember-truth-helpers if an app uses both freestyle and ember-truth-helpers. Consider making the helper freestyle-eq OR investigate whether there is a way for a helper to be included in addons/ tree only.

Copy link
Owner Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Heh, good call!

1 change: 0 additions & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -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"
Expand Down
62 changes: 28 additions & 34 deletions yarn.lock
Original file line number Diff line number Diff line change
Expand Up @@ -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"
Expand Down Expand Up @@ -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:
Expand All @@ -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:
Expand Down Expand Up @@ -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:
Expand All @@ -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"
Expand Down