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

move funcs folder to new helpers folder #24

Merged
merged 1 commit into from
Jan 11, 2017
Merged
Show file tree
Hide file tree
Changes from all commits
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
2 changes: 1 addition & 1 deletion combinators/applyTo.js
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
/** @license ISC License (c) copyright 2016 original and current authors */
/** @author Ian Hofmann-Hicks (evil) */

const curry = require('../funcs/curry')
const curry = require('../helpers/curry')
const isFunction = require('../internal/isFunction')

// Applicator
Expand Down
2 changes: 1 addition & 1 deletion combinators/composeB.js
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
/** @license ISC License (c) copyright 2016 original and current authors */
/** @author Ian Hofmann-Hicks (evil) */

const curry = require('../funcs/curry')
const curry = require('../helpers/curry')
const isFunction = require('../internal/isFunction')

// Composition (Bluebird)
Expand Down
2 changes: 1 addition & 1 deletion combinators/constant.js
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
/** @license ISC License (c) copyright 2016 original and current authors */
/** @author Ian Hofmann-Hicks (evil) */

const curry = require('../funcs/curry')
const curry = require('../helpers/curry')

// Constant (Kestrel)
// constant :: a -> b -> a
Expand Down
2 changes: 1 addition & 1 deletion combinators/flip.js
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
/** @license ISC License (c) copyright 2016 original and current authors */
/** @author Ian Hofmann-Hicks (evil) */

const curry = require('../funcs/curry')
const curry = require('../helpers/curry')
const isFunction = require('../internal/isFunction')

// Flip (Cardinal)
Expand Down
2 changes: 1 addition & 1 deletion combinators/reverseApply.js
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
/** @license ISC License (c) copyright 2016 original and current authors */
/** @author Ian Hofmann-Hicks (evil) */

const curry = require('../funcs/curry')
const curry = require('../helpers/curry')
const isFunction = require('../internal/isFunction')

// Reverse Application (Thrush)
Expand Down
2 changes: 1 addition & 1 deletion combinators/substitution.js
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
/** @license ISC License (c) copyright 2016 original and current authors */
/** @author Ian Hofmann-Hicks (evil) */

const curry = require('../funcs/curry')
const curry = require('../helpers/curry')
const isFunction = require('../internal/isFunction')

// Substitution (Starling)
Expand Down
34 changes: 17 additions & 17 deletions crocks.js
Original file line number Diff line number Diff line change
Expand Up @@ -29,23 +29,23 @@ const monoids = {
}

const helpers = {
branch: require('./funcs/branch'),
compose: require('./funcs/compose'),
curry: require('./funcs/curry'),
curryN: require('./funcs/curryN'),
ifElse: require('./funcs/ifElse'),
inspect: require('./funcs/inspect'),
liftA2: require('./funcs/liftA2'),
liftA3: require('./funcs/liftA3'),
mconcat: require('./funcs/mconcat'),
mconcatMap: require('./funcs/mconcatMap'),
mreduce: require('./funcs/mreduce'),
mreduceMap: require('./funcs/mreduceMap'),
pipe: require('./funcs/pipe'),
safe: require('./funcs/safe'),
tryCatch: require('./funcs/tryCatch'),
unless: require('./funcs/unless'),
when: require('./funcs/when')
branch: require('./helpers/branch'),
compose: require('./helpers/compose'),
curry: require('./helpers/curry'),
curryN: require('./helpers/curryN'),
ifElse: require('./helpers/ifElse'),
inspect: require('./helpers/inspect'),
liftA2: require('./helpers/liftA2'),
liftA3: require('./helpers/liftA3'),
mconcat: require('./helpers/mconcat'),
mconcatMap: require('./helpers/mconcatMap'),
mreduce: require('./helpers/mreduce'),
mreduceMap: require('./helpers/mreduceMap'),
pipe: require('./helpers/pipe'),
safe: require('./helpers/safe'),
tryCatch: require('./helpers/tryCatch'),
unless: require('./helpers/unless'),
when: require('./helpers/when')
}

const pointFree = {
Expand Down
34 changes: 17 additions & 17 deletions crocks.spec.js
Original file line number Diff line number Diff line change
Expand Up @@ -10,23 +10,23 @@ const identity = require('./combinators/identity')
const reverseApply = require('./combinators/reverseApply')
const substitution = require('./combinators/substitution')

const branch = require('./funcs/branch')
const compose = require('./funcs/compose')
const curry = require('./funcs/curry')
const curryN = require('./funcs/curryN')
const ifElse = require('./funcs/ifElse')
const inspect = require('./funcs/inspect')
const liftA2 = require('./funcs/liftA2')
const liftA3 = require('./funcs/liftA3')
const mconcat = require('./funcs/mconcat')
const mconcatMap = require('./funcs/mconcatMap')
const mreduce = require('./funcs/mreduce')
const mreduceMap = require('./funcs/mreduceMap')
const pipe = require('./funcs/pipe')
const safe = require('./funcs/safe')
const tryCatch = require('./funcs/tryCatch')
const unless = require('./funcs/unless')
const when = require('./funcs/when')
const branch = require('./helpers/branch')
const compose = require('./helpers/compose')
const curry = require('./helpers/curry')
const curryN = require('./helpers/curryN')
const ifElse = require('./helpers/ifElse')
const inspect = require('./helpers/inspect')
const liftA2 = require('./helpers/liftA2')
const liftA3 = require('./helpers/liftA3')
const mconcat = require('./helpers/mconcat')
const mconcatMap = require('./helpers/mconcatMap')
const mreduce = require('./helpers/mreduce')
const mreduceMap = require('./helpers/mreduceMap')
const pipe = require('./helpers/pipe')
const safe = require('./helpers/safe')
const tryCatch = require('./helpers/tryCatch')
const unless = require('./helpers/unless')
const when = require('./helpers/when')

const ap = require('./pointfree/ap')
const bimap = require('./pointfree/bimap')
Expand Down
4 changes: 2 additions & 2 deletions crocks/Arrow.js
Original file line number Diff line number Diff line change
Expand Up @@ -4,11 +4,11 @@
const isFunction = require('../internal/isFunction')
const isType = require('../internal/isType')

const _inspect = require('../funcs/inspect')
const _inspect = require('../helpers/inspect')
const compose = require('../helpers/compose')

const identity = require('../combinators/identity')
const constant = require('../combinators/constant')
const compose = require('../funcs/compose')

const Pair = require('./Pair')

Expand Down
2 changes: 1 addition & 1 deletion crocks/Const.js
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
const isFunction = require('../internal/isFunction')
const isType = require('../internal/isType')

const _inspect = require('../funcs/inspect')
const _inspect = require('../helpers/inspect')

const constant = require('../combinators/constant')

Expand Down
2 changes: 1 addition & 1 deletion crocks/Either.js
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ const constant = require('../combinators/constant')
const composeB = require('../combinators/composeB')
const identity = require('../combinators/identity')

const _inspect = require('../funcs/inspect')
const _inspect = require('../helpers/inspect')

const _either = defineUnion({ Left: [ 'a' ], Right: [ 'b' ] })

Expand Down
2 changes: 1 addition & 1 deletion crocks/IO.js
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
const isFunction = require('../internal/isFunction')
const isType = require('../internal/isType')

const _inspect = require('../funcs/inspect')
const _inspect = require('../helpers/inspect')

const composeB = require('../combinators/composeB')
const constant = require('../combinators/constant')
Expand Down
2 changes: 1 addition & 1 deletion crocks/Identity.js
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ const isFunction = require('../internal/isFunction')
const isType = require('../internal/isType')
const isApplicative = require('../internal/isApplicative')

const _inspect = require('../funcs/inspect')
const _inspect = require('../helpers/inspect')

const constant = require('../combinators/constant')
const composeB = require('../combinators/composeB')
Expand Down
2 changes: 1 addition & 1 deletion crocks/List.js
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ const isApplicative = require('../internal/isApplicative')

const constant = require('../combinators/constant')

const _inspect = require('../funcs/inspect')
const _inspect = require('../helpers/inspect')
const _concat = require('../pointfree/concat')

const Maybe = require('./Maybe')
Expand Down
2 changes: 1 addition & 1 deletion crocks/Maybe.js
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ const constant = require('../combinators/constant')
const identity = require('../combinators/identity')
const composeB = require('../combinators/composeB')

const _inspect = require('../funcs/inspect')
const _inspect = require('../helpers/inspect')

const _maybe = defineUnion({ Nothing: [], Just: [ 'a' ] })

Expand Down
2 changes: 1 addition & 1 deletion crocks/Pair.js
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ const isType = require('../internal/isType')
const isFunction = require('../internal/isFunction')
const isSemigroup = require('../internal/isSemigroup')

const _inspect = require('../funcs/inspect')
const _inspect = require('../helpers/inspect')

const constant = require('../combinators/constant')

Expand Down
2 changes: 1 addition & 1 deletion crocks/Pred.js
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
const isFunction = require('../internal/isFunction')
const isType = require('../internal/isType')

const _inspect = require('../funcs/inspect')
const _inspect = require('../helpers/inspect')

const constant = require('../combinators/constant')
const composeB = require('../combinators/composeB')
Expand Down
2 changes: 1 addition & 1 deletion crocks/Reader.js
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
const isFunction = require('../internal/isFunction')
const isType = require('../internal/isType')

const _inspect = require('../funcs/inspect')
const _inspect = require('../helpers/inspect')

const composeB = require('../combinators/composeB')
const constant = require('../combinators/constant')
Expand Down
4 changes: 2 additions & 2 deletions crocks/Star.js
Original file line number Diff line number Diff line change
Expand Up @@ -4,10 +4,10 @@
const isFunction = require('../internal/isFunction')
const isFunctor = require('../internal/isFunctor')

const _inspect = require('../funcs/inspect')
const _inspect = require('../helpers/inspect')

const constant = require('../combinators/constant')
const compose = require('../funcs/compose')
const compose = require('../helpers/compose')

const _type =
constant('Star')
Expand Down
2 changes: 1 addition & 1 deletion crocks/State.js
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
const isFunction = require('../internal/isFunction')
const isType = require('../internal/isType')

const _inspect = require('../funcs/inspect')
const _inspect = require('../helpers/inspect')

const constant = require('../combinators/constant')

Expand Down
2 changes: 1 addition & 1 deletion crocks/Unit.js
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
const isFunction = require('../internal/isFunction')
const isType = require('../internal/isType')

const _inspect = require('../funcs/inspect')
const _inspect = require('../helpers/inspect')

const constant = require('../combinators/constant')

Expand Down
2 changes: 1 addition & 1 deletion crocks/Writer.js
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ const isType = require('../internal/isType')
const isFunction = require('../internal/isFunction')
const isMonoid = require('../internal/isMonoid')

const _inspect = require('../funcs/inspect')
const _inspect = require('../helpers/inspect')

const constant = require('../combinators/constant')

Expand Down
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
2 changes: 1 addition & 1 deletion internal/defineUnion.js
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
/** @license ISC License (c) copyright 2016 original and current authors */
/** @author Ian Hofmann-Hicks (evil) */

const curry = require('../funcs/curry')
const curry = require('../helpers/curry')
const constant = require('../combinators/constant')
const argsArray = require('./argsArray')

Expand Down
2 changes: 1 addition & 1 deletion monoids/All.js
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ const isType = require('../internal/isType')
const isFunction = require('../internal/isFunction')
const isNil = require('../internal/isNil')

const _inspect = require('../funcs/inspect')
const _inspect = require('../helpers/inspect')

const constant = require('../combinators/constant')

Expand Down
2 changes: 1 addition & 1 deletion monoids/Any.js
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ const isType = require('../internal/isType')
const isFunction = require('../internal/isFunction')
const isNil = require('../internal/isNil')

const _inspect = require('../funcs/inspect')
const _inspect = require('../helpers/inspect')

const constant = require('../combinators/constant')

Expand Down
2 changes: 1 addition & 1 deletion monoids/Assign.js
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ const isObject = require('../internal/isObject')
const isFunction = require('../internal/isFunction')
const isNil = require('../internal/isNil')

const _inspect = require('../funcs/inspect')
const _inspect = require('../helpers/inspect')

const constant = require('../combinators/constant')

Expand Down
2 changes: 1 addition & 1 deletion monoids/Max.js
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ const isType = require('../internal/isType')
const isNumber = require('../internal/isNumber')
const isNil = require('../internal/isNil')

const _inspect = require('../funcs/inspect')
const _inspect = require('../helpers/inspect')

const constant = require('../combinators/constant')

Expand Down
2 changes: 1 addition & 1 deletion monoids/Min.js
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ const isType = require('../internal/isType')
const isNumber = require('../internal/isNumber')
const isNil = require('../internal/isNil')

const _inspect = require('../funcs/inspect')
const _inspect = require('../helpers/inspect')

const constant = require('../combinators/constant')

Expand Down
2 changes: 1 addition & 1 deletion monoids/Prod.js
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ const isNumber = require('../internal/isNumber')
const isFunction = require('../internal/isFunction')
const isNil = require('../internal/isNil')

const _inspect = require('../funcs/inspect')
const _inspect = require('../helpers/inspect')

const constant = require('../combinators/constant')

Expand Down
2 changes: 1 addition & 1 deletion monoids/Sum.js
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ const isNumber = require('../internal/isNumber')
const isFunction = require('../internal/isFunction')
const isNil = require('../internal/isNil')

const _inspect = require('../funcs/inspect')
const _inspect = require('../helpers/inspect')

const constant = require('../combinators/constant')

Expand Down
2 changes: 1 addition & 1 deletion pointfree/ap.js
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
/** @license ISC License (c) copyright 2016 original and current authors */
/** @author Ian Hofmann-Hicks (evil) */

const curry = require('../funcs/curry')
const curry = require('../helpers/curry')
const isFunction = require('../internal/isFunction')

// ap :: Applicative m => m a -> m (a -> b) -> m b
Expand Down
2 changes: 1 addition & 1 deletion pointfree/bimap.js
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
/** @license ISC License (c) copyright 2016 original and current authors */
/** @author Ian Hofmann-Hicks (evil) */

const curry = require('../funcs/curry')
const curry = require('../helpers/curry')
const isFunction = require('../internal/isFunction')

function bimap(f, g, m) {
Expand Down
2 changes: 1 addition & 1 deletion pointfree/chain.js
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
/** @license ISC License (c) copyright 2016 original and current authors */
/** @author Ian Hofmann-Hicks (evil) */

const curry = require('../funcs/curry')
const curry = require('../helpers/curry')
const isFunction = require('../internal/isFunction')

// chain :: Chain m => (a -> m b) -> m a -> m b
Expand Down
2 changes: 1 addition & 1 deletion pointfree/coalesce.js
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
/** @license ISC License (c) copyright 2016 original and current authors */
/** @author Ian Hofmann-Hicks (evil) */

const curry = require('../funcs/curry')
const curry = require('../helpers/curry')
const isFunction = require('../internal/isFunction')

function coalesce(f, g, m) {
Expand Down
2 changes: 1 addition & 1 deletion pointfree/concat.js
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
/** @license ISC License (c) copyright 2016 original and current authors */
/** @author Ian Hofmann-Hicks (evil) */

const curry = require('../funcs/curry')
const curry = require('../helpers/curry')
const isString = require('../internal/isString')
const isSemigroup = require('../internal/isSemigroup')

Expand Down
2 changes: 1 addition & 1 deletion pointfree/cons.js
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
/** @license ISC License (c) copyright 2016 original and current authors */
/** @author Ian Hofmann-Hicks (evil) */

const curry = require('../funcs/curry')
const curry = require('../helpers/curry')
const isArray = require('../internal/isArray')
const isFunction = require('../internal/isFunction')

Expand Down
Loading