From bd55f862030b9fff955941f6e776524c68a4a795 Mon Sep 17 00:00:00 2001 From: John-David Dalton Date: Tue, 19 Nov 2013 21:26:06 -0800 Subject: [PATCH] Indicate aliases with `->` in docs. --- doc/README.md | 328 +++++++++--------- .../docdown/src/DocDown/MarkdownGenerator.php | 26 +- 2 files changed, 188 insertions(+), 166 deletions(-) diff --git a/doc/README.md b/doc/README.md index 1a77fa7fd..0a0ed80ed 100644 --- a/doc/README.md +++ b/doc/README.md @@ -6,34 +6,34 @@ ## `Arrays` -* [`_.compact`](#_compactarray) -* [`_.difference`](#_differencearray-values) -* [`_.drop`](#_restarray-callback1-thisarg) -* [`_.findIndex`](#_findindexarray-callbackidentity-thisarg) -* [`_.findLastIndex`](#_findlastindexarray-callbackidentity-thisarg) -* [`_.first`](#_firstarray-callback-thisarg) -* [`_.flatten`](#_flattenarray-isshallowfalse-callbackidentity-thisarg) -* [`_.head`](#_firstarray-callback-thisarg) -* [`_.indexOf`](#_indexofarray-value-fromindex0) -* [`_.initial`](#_initialarray-callback1-thisarg) -* [`_.intersection`](#_intersectionarray) -* [`_.last`](#_lastarray-callback-thisarg) -* [`_.lastIndexOf`](#_lastindexofarray-value-fromindexarraylength-1) -* [`_.object`](#_zipobjectkeys-values) -* [`_.pull`](#_pullarray-value) -* [`_.range`](#_rangestart0-end-step1) -* [`_.remove`](#_removearray-callbackidentity-thisarg) -* [`_.rest`](#_restarray-callback1-thisarg) -* [`_.sortedIndex`](#_sortedindexarray-value-callbackidentity-thisarg) -* [`_.tail`](#_restarray-callback1-thisarg) -* [`_.take`](#_firstarray-callback-thisarg) -* [`_.union`](#_unionarray) -* [`_.uniq`](#_uniqarray-issortedfalse-callbackidentity-thisarg) -* [`_.unique`](#_uniqarray-issortedfalse-callbackidentity-thisarg) -* [`_.unzip`](#_ziparray) -* [`_.without`](#_withoutarray-value) -* [`_.zip`](#_ziparray) -* [`_.zipObject`](#_zipobjectkeys-values) +* `_.compact` +* `_.difference` +* `_.drop -> rest` +* `_.findIndex` +* `_.findLastIndex` +* `_.first` +* `_.flatten` +* `_.head -> first` +* `_.indexOf` +* `_.initial` +* `_.intersection` +* `_.last` +* `_.lastIndexOf` +* `_.object -> zipObject` +* `_.pull` +* `_.range` +* `_.remove` +* `_.rest` +* `_.sortedIndex` +* `_.tail -> rest` +* `_.take -> first` +* `_.union` +* `_.uniq` +* `_.unique -> uniq` +* `_.unzip -> zip` +* `_.without` +* `_.zip` +* `_.zipObject` @@ -41,13 +41,13 @@ ## `Chaining` -* [`_`](#_value) -* [`_.chain`](#_chainvalue) -* [`_.tap`](#_tapvalue-interceptor) -* [`_.prototype.chain`](#_prototypechain) -* [`_.prototype.toString`](#_prototypetostring) -* [`_.prototype.value`](#_prototypevalueof) -* [`_.prototype.valueOf`](#_prototypevalueof) +* `_` +* `_.chain` +* `_.tap` +* `_.prototype.chain` +* `_.prototype.toString` +* `_.prototype.value -> valueOf` +* `_.prototype.valueOf` @@ -55,44 +55,44 @@ ## `Collections` -* [`_.all`](#_everycollection-callbackidentity-thisarg) -* [`_.any`](#_somecollection-callbackidentity-thisarg) -* [`_.at`](#_atcollection-index) -* [`_.collect`](#_mapcollection-callbackidentity-thisarg) -* [`_.contains`](#_containscollection-target-fromindex0) -* [`_.countBy`](#_countbycollection-callbackidentity-thisarg) -* [`_.detect`](#_findcollection-callbackidentity-thisarg) -* [`_.each`](#_foreachcollection-callbackidentity-thisarg) -* [`_.eachRight`](#_foreachrightcollection-callbackidentity-thisarg) -* [`_.every`](#_everycollection-callbackidentity-thisarg) -* [`_.filter`](#_filtercollection-callbackidentity-thisarg) -* [`_.find`](#_findcollection-callbackidentity-thisarg) -* [`_.findLast`](#_findlastcollection-callbackidentity-thisarg) -* [`_.findWhere`](#_findcollection-callbackidentity-thisarg) -* [`_.foldl`](#_reducecollection-callbackidentity-accumulator-thisarg) -* [`_.foldr`](#_reducerightcollection-callbackidentity-accumulator-thisarg) -* [`_.forEach`](#_foreachcollection-callbackidentity-thisarg) -* [`_.forEachRight`](#_foreachrightcollection-callbackidentity-thisarg) -* [`_.groupBy`](#_groupbycollection-callbackidentity-thisarg) -* [`_.include`](#_containscollection-target-fromindex0) -* [`_.indexBy`](#_indexbycollection-callbackidentity-thisarg) -* [`_.inject`](#_reducecollection-callbackidentity-accumulator-thisarg) -* [`_.invoke`](#_invokecollection-methodname-arg) -* [`_.map`](#_mapcollection-callbackidentity-thisarg) -* [`_.max`](#_maxcollection-callbackidentity-thisarg) -* [`_.min`](#_mincollection-callbackidentity-thisarg) -* [`_.pluck`](#_pluckcollection-property) -* [`_.reduce`](#_reducecollection-callbackidentity-accumulator-thisarg) -* [`_.reduceRight`](#_reducerightcollection-callbackidentity-accumulator-thisarg) -* [`_.reject`](#_rejectcollection-callbackidentity-thisarg) -* [`_.sample`](#_samplecollection-n) -* [`_.select`](#_filtercollection-callbackidentity-thisarg) -* [`_.shuffle`](#_shufflecollection) -* [`_.size`](#_sizecollection) -* [`_.some`](#_somecollection-callbackidentity-thisarg) -* [`_.sortBy`](#_sortbycollection-callbackidentity-thisarg) -* [`_.toArray`](#_toarraycollection) -* [`_.where`](#_wherecollection-props) +* `_.all -> every` +* `_.any -> some` +* `_.at` +* `_.collect -> map` +* `_.contains` +* `_.countBy` +* `_.detect -> find` +* `_.each -> forEach` +* `_.eachRight -> forEachRight` +* `_.every` +* `_.filter` +* `_.find` +* `_.findLast` +* `_.findWhere -> find` +* `_.foldl -> reduce` +* `_.foldr -> reduceRight` +* `_.forEach` +* `_.forEachRight` +* `_.groupBy` +* `_.include -> contains` +* `_.indexBy` +* `_.inject -> reduce` +* `_.invoke` +* `_.map` +* `_.max` +* `_.min` +* `_.pluck` +* `_.reduce` +* `_.reduceRight` +* `_.reject` +* `_.sample` +* `_.select -> filter` +* `_.shuffle` +* `_.size` +* `_.some` +* `_.sortBy` +* `_.toArray` +* `_.where` @@ -100,23 +100,23 @@ ## `Functions` -* [`_.after`](#_aftern-func) -* [`_.bind`](#_bindfunc-thisarg-arg) -* [`_.bindAll`](#_bindallobject-methodname) -* [`_.bindKey`](#_bindkeyobject-key-arg) -* [`_.compose`](#_composefunc) -* [`_.createCallback`](#_createcallbackfuncidentity-thisarg-argcount) -* [`_.curry`](#_curryfunc-arityfunclength) -* [`_.debounce`](#_debouncefunc-wait-options-optionsmaxwait) -* [`_.defer`](#_deferfunc-arg) -* [`_.delay`](#_delayfunc-wait-arg) -* [`_.memoize`](#_memoizefunc-resolver) -* [`_.once`](#_oncefunc) -* [`_.partial`](#_partialfunc-arg) -* [`_.partialRight`](#_partialrightfunc-arg) -* [`_.property`](#_propertyprop) -* [`_.throttle`](#_throttlefunc-wait-options) -* [`_.wrap`](#_wrapvalue-wrapper) +* `_.after` +* `_.bind` +* `_.bindAll` +* `_.bindKey` +* `_.compose` +* `_.createCallback` +* `_.curry` +* `_.debounce` +* `_.defer` +* `_.delay` +* `_.memoize` +* `_.once` +* `_.partial` +* `_.partialRight` +* `_.property` +* `_.throttle` +* `_.wrap` @@ -124,46 +124,46 @@ ## `Objects` -* [`_.assign`](#_assignobject-source-callback-thisarg) -* [`_.clone`](#_clonevalue-isdeepfalse-callback-thisarg) -* [`_.cloneDeep`](#_clonedeepvalue-callback-thisarg) -* [`_.create`](#_createprototype-properties) -* [`_.defaults`](#_defaultsobject-source) -* [`_.extend`](#_assignobject-source-callback-thisarg) -* [`_.findKey`](#_findkeyobject-callbackidentity-thisarg) -* [`_.findLastKey`](#_findlastkeyobject-callbackidentity-thisarg) -* [`_.forIn`](#_forinobject-callbackidentity-thisarg) -* [`_.forInRight`](#_forinrightobject-callbackidentity-thisarg) -* [`_.forOwn`](#_forownobject-callbackidentity-thisarg) -* [`_.forOwnRight`](#_forownrightobject-callbackidentity-thisarg) -* [`_.functions`](#_functionsobject) -* [`_.has`](#_hasobject-prop) -* [`_.invert`](#_invertobject) -* [`_.isArguments`](#_isargumentsvalue) -* [`_.isArray`](#_isarrayvalue) -* [`_.isBoolean`](#_isbooleanvalue) -* [`_.isDate`](#_isdatevalue) -* [`_.isElement`](#_iselementvalue) -* [`_.isEmpty`](#_isemptyvalue) -* [`_.isEqual`](#_isequala-b-callback-thisarg) -* [`_.isFinite`](#_isfinitevalue) -* [`_.isFunction`](#_isfunctionvalue) -* [`_.isNaN`](#_isnanvalue) -* [`_.isNull`](#_isnullvalue) -* [`_.isNumber`](#_isnumbervalue) -* [`_.isObject`](#_isobjectvalue) -* [`_.isPlainObject`](#_isplainobjectvalue) -* [`_.isRegExp`](#_isregexpvalue) -* [`_.isString`](#_isstringvalue) -* [`_.isUndefined`](#_isundefinedvalue) -* [`_.keys`](#_keysobject) -* [`_.merge`](#_mergeobject-source-callback-thisarg) -* [`_.methods`](#_functionsobject) -* [`_.omit`](#_omitobject-callback-thisarg) -* [`_.pairs`](#_pairsobject) -* [`_.pick`](#_pickobject-callback-thisarg) -* [`_.transform`](#_transformobject-callbackidentity-accumulator-thisarg) -* [`_.values`](#_valuesobject) +* `_.assign` +* `_.clone` +* `_.cloneDeep` +* `_.create` +* `_.defaults` +* `_.extend -> assign` +* `_.findKey` +* `_.findLastKey` +* `_.forIn` +* `_.forInRight` +* `_.forOwn` +* `_.forOwnRight` +* `_.functions` +* `_.has` +* `_.invert` +* `_.isArguments` +* `_.isArray` +* `_.isBoolean` +* `_.isDate` +* `_.isElement` +* `_.isEmpty` +* `_.isEqual` +* `_.isFinite` +* `_.isFunction` +* `_.isNaN` +* `_.isNull` +* `_.isNumber` +* `_.isObject` +* `_.isPlainObject` +* `_.isRegExp` +* `_.isString` +* `_.isUndefined` +* `_.keys` +* `_.merge` +* `_.methods -> functions` +* `_.omit` +* `_.pairs` +* `_.pick` +* `_.transform` +* `_.values` @@ -171,20 +171,20 @@ ## `Utilities` -* [`_.now`](#_now) -* [`_.escape`](#_escapestring) -* [`_.identity`](#_identityvalue) -* [`_.mixin`](#_mixinobject-object) -* [`_.noConflict`](#_noconflict) -* [`_.noop`](#_noop) -* [`_.parseInt`](#_parseintvalue-radix) -* [`_.random`](#_randommin0-max1-floatingfalse) -* [`_.result`](#_resultobject-prop) -* [`_.runInContext`](#_runincontextcontextroot) -* [`_.template`](#_templatetext-data-options-optionsescape-optionsevaluate-optionsimports-optionsinterpolate-sourceurl-variable) -* [`_.times`](#_timesn-callback-thisarg) -* [`_.unescape`](#_unescapestring) -* [`_.uniqueId`](#_uniqueidprefix) +* `_.now` +* `_.escape` +* `_.identity` +* `_.mixin` +* `_.noConflict` +* `_.noop` +* `_.parseInt` +* `_.random` +* `_.result` +* `_.runInContext` +* `_.template` +* `_.times` +* `_.unescape` +* `_.uniqueId` @@ -192,7 +192,7 @@ ## `Methods` -* [`_.templateSettings.imports._`](#_templatesettingsimports_) +* `_.templateSettings.imports._` @@ -200,25 +200,25 @@ ## `Properties` -* [`_.VERSION`](#_version) -* [`_.support`](#_support) -* [`_.support.argsClass`](#_supportargsclass) -* [`_.support.argsObject`](#_supportargsobject) -* [`_.support.enumErrorProps`](#_supportenumerrorprops) -* [`_.support.enumPrototypes`](#_supportenumprototypes) -* [`_.support.funcDecomp`](#_supportfuncdecomp) -* [`_.support.funcNames`](#_supportfuncnames) -* [`_.support.nonEnumArgs`](#_supportnonenumargs) -* [`_.support.nonEnumShadows`](#_supportnonenumshadows) -* [`_.support.ownLast`](#_supportownlast) -* [`_.support.spliceObjects`](#_supportspliceobjects) -* [`_.support.unindexedChars`](#_supportunindexedchars) -* [`_.templateSettings`](#_templatesettings) -* [`_.templateSettings.escape`](#_templatesettingsescape) -* [`_.templateSettings.evaluate`](#_templatesettingsevaluate) -* [`_.templateSettings.interpolate`](#_templatesettingsinterpolate) -* [`_.templateSettings.variable`](#_templatesettingsvariable) -* [`_.templateSettings.imports`](#_templatesettingsimports) +* `_.VERSION` +* `_.support` +* `_.support.argsClass` +* `_.support.argsObject` +* `_.support.enumErrorProps` +* `_.support.enumPrototypes` +* `_.support.funcDecomp` +* `_.support.funcNames` +* `_.support.nonEnumArgs` +* `_.support.nonEnumShadows` +* `_.support.ownLast` +* `_.support.spliceObjects` +* `_.support.unindexedChars` +* `_.templateSettings` +* `_.templateSettings.escape` +* `_.templateSettings.evaluate` +* `_.templateSettings.interpolate` +* `_.templateSettings.variable` +* `_.templateSettings.imports` diff --git a/vendor/docdown/src/DocDown/MarkdownGenerator.php b/vendor/docdown/src/DocDown/MarkdownGenerator.php index c08956621..f6ffb6ac7 100644 --- a/vendor/docdown/src/DocDown/MarkdownGenerator.php +++ b/vendor/docdown/src/DocDown/MarkdownGenerator.php @@ -516,7 +516,18 @@ class MarkdownGenerator { ); // add entries foreach ($entries as $entry) { - $result[] = MarkdownGenerator::interpolate('* [`#{member}#{separator}#{name}`](##{hash})', $entry); + if ($entry->isAlias()) { + $result[] = MarkdownGenerator::interpolate('* `#{member}#{separator}#{name} -> #{realName}`', array( + 'hash' => $entry->hash, + 'member' => $entry->member, + 'name' => $entry->getName(), + 'realName' => $entry->owner->getName(), + 'separator' => $entry->separator + )); + } + else { + $result[] = MarkdownGenerator::interpolate('* `#{member}#{separator}#{name}`', $entry); + } } } } @@ -553,7 +564,18 @@ class MarkdownGenerator { } foreach ($entry->{$kind} as $subentry) { $subentry->member = $member; - $result[] = MarkdownGenerator::interpolate('* [`#{member}#{separator}#{name}`](##{hash})', $subentry); + if ($subentry->isAlias()) { + $result[] = MarkdownGenerator::interpolate('* `#{member}#{separator}#{name} -> #{realName}`', array( + 'hash' => $subentry->hash, + 'member' => $subentry->member, + 'name' => $subentry->getName(), + 'realName' => $subentry->owner->getName(), + 'separator' => $subentry->separator + )); + } + else { + $result[] = MarkdownGenerator::interpolate('* `#{member}#{separator}#{name}`', $subentry); + } } } }