diff --git a/package.json b/package.json index d83a8a1066..34f2440488 100644 --- a/package.json +++ b/package.json @@ -153,6 +153,7 @@ "coveralls": "^2.11.13", "cz-conventional-changelog": "^1.2.0", "doctoc": "^1.0.0", + "escape-string-regexp": "^1.0.5 ", "esdoc": "^0.4.7", "eslint": "^2.12.0", "fs-extra": "^0.30.0", diff --git a/spec/helpers/ambient.d.ts b/spec/helpers/ambient.d.ts index 3956841d80..354c8b6530 100644 --- a/spec/helpers/ambient.d.ts +++ b/spec/helpers/ambient.d.ts @@ -9,4 +9,4 @@ declare module 'mocha/lib/suite' { } declare module 'mocha/lib/test' { -} \ No newline at end of file +} diff --git a/src/MiscJSDoc.ts b/src/MiscJSDoc.ts index d9ca775a61..fe284b8647 100644 --- a/src/MiscJSDoc.ts +++ b/src/MiscJSDoc.ts @@ -14,7 +14,7 @@ import './observable/dom/MiscJSDoc'; /** * We need this JSDoc comment for affecting ESDoc. * @extends {Ignored} - * @hide true + * @ignore */ export class ObservableDoc { /** diff --git a/src/observable/ArrayLikeObservable.ts b/src/observable/ArrayLikeObservable.ts index c0c46dc477..30586975b4 100644 --- a/src/observable/ArrayLikeObservable.ts +++ b/src/observable/ArrayLikeObservable.ts @@ -8,7 +8,7 @@ import { TeardownLogic } from '../Subscription'; /** * We need this JSDoc comment for affecting ESDoc. * @extends {Ignored} - * @hide true + * @ignore */ export class ArrayLikeObservable extends Observable { diff --git a/src/observable/ArrayObservable.ts b/src/observable/ArrayObservable.ts index eff3621af5..fb60608b3e 100644 --- a/src/observable/ArrayObservable.ts +++ b/src/observable/ArrayObservable.ts @@ -9,7 +9,7 @@ import { TeardownLogic } from '../Subscription'; /** * We need this JSDoc comment for affecting ESDoc. * @extends {Ignored} - * @hide true + * @ignore */ export class ArrayObservable extends Observable { diff --git a/src/observable/BoundCallbackObservable.ts b/src/observable/BoundCallbackObservable.ts index b5edd4fe51..0b160385c8 100644 --- a/src/observable/BoundCallbackObservable.ts +++ b/src/observable/BoundCallbackObservable.ts @@ -9,7 +9,7 @@ import { AsyncSubject } from '../AsyncSubject'; /** * We need this JSDoc comment for affecting ESDoc. * @extends {Ignored} - * @hide true + * @ignore */ export class BoundCallbackObservable extends Observable { subject: AsyncSubject; diff --git a/src/observable/BoundNodeCallbackObservable.ts b/src/observable/BoundNodeCallbackObservable.ts index 6405abea49..efa8fae126 100644 --- a/src/observable/BoundNodeCallbackObservable.ts +++ b/src/observable/BoundNodeCallbackObservable.ts @@ -9,7 +9,7 @@ import { AsyncSubject } from '../AsyncSubject'; /** * We need this JSDoc comment for affecting ESDoc. * @extends {Ignored} - * @hide true + * @ignore */ export class BoundNodeCallbackObservable extends Observable { subject: AsyncSubject; diff --git a/src/observable/DeferObservable.ts b/src/observable/DeferObservable.ts index 8f8dcabd91..328d1a6394 100644 --- a/src/observable/DeferObservable.ts +++ b/src/observable/DeferObservable.ts @@ -7,7 +7,7 @@ import { OuterSubscriber } from '../OuterSubscriber'; /** * We need this JSDoc comment for affecting ESDoc. * @extends {Ignored} - * @hide true + * @ignore */ export class DeferObservable extends Observable { diff --git a/src/observable/EmptyObservable.ts b/src/observable/EmptyObservable.ts index be550b0a60..77596497a2 100644 --- a/src/observable/EmptyObservable.ts +++ b/src/observable/EmptyObservable.ts @@ -10,7 +10,7 @@ export interface DispatchArg { /** * We need this JSDoc comment for affecting ESDoc. * @extends {Ignored} - * @hide true + * @ignore */ export class EmptyObservable extends Observable { diff --git a/src/observable/ErrorObservable.ts b/src/observable/ErrorObservable.ts index aa18fcf723..b905458981 100644 --- a/src/observable/ErrorObservable.ts +++ b/src/observable/ErrorObservable.ts @@ -10,7 +10,7 @@ export interface DispatchArg { /** * We need this JSDoc comment for affecting ESDoc. * @extends {Ignored} - * @hide true + * @ignore */ export class ErrorObservable extends Observable { diff --git a/src/observable/ForkJoinObservable.ts b/src/observable/ForkJoinObservable.ts index 86c06f2464..cdb3a393d7 100644 --- a/src/observable/ForkJoinObservable.ts +++ b/src/observable/ForkJoinObservable.ts @@ -11,7 +11,7 @@ import { InnerSubscriber } from '../InnerSubscriber'; /** * We need this JSDoc comment for affecting ESDoc. * @extends {Ignored} - * @hide true + * @ignore */ export class ForkJoinObservable extends Observable { constructor(private sources: Array>, @@ -138,4 +138,4 @@ class ForkJoinSubscriber extends OuterSubscriber { destination.complete(); } -} \ No newline at end of file +} diff --git a/src/observable/FromEventObservable.ts b/src/observable/FromEventObservable.ts index a104d7eda9..da857d9278 100644 --- a/src/observable/FromEventObservable.ts +++ b/src/observable/FromEventObservable.ts @@ -46,7 +46,7 @@ export type SelectorMethodSignature = (...args: Array) => T; /** * We need this JSDoc comment for affecting ESDoc. * @extends {Ignored} - * @hide true + * @ignore */ export class FromEventObservable extends Observable { diff --git a/src/observable/FromEventPatternObservable.ts b/src/observable/FromEventPatternObservable.ts index a48e6f5659..fa16d1289a 100644 --- a/src/observable/FromEventPatternObservable.ts +++ b/src/observable/FromEventPatternObservable.ts @@ -5,7 +5,7 @@ import { Subscriber } from '../Subscriber'; /** * We need this JSDoc comment for affecting ESDoc. * @extends {Ignored} - * @hide true + * @ignore */ export class FromEventPatternObservable extends Observable { @@ -100,4 +100,4 @@ export class FromEventPatternObservable extends Observable { errorSubscriber.error(e); } } -} \ No newline at end of file +} diff --git a/src/observable/FromObservable.ts b/src/observable/FromObservable.ts index 10f6bc6ee0..9c1a9314cd 100644 --- a/src/observable/FromObservable.ts +++ b/src/observable/FromObservable.ts @@ -17,7 +17,7 @@ const isArrayLike = ((x: any): x is ArrayLike => x && typeof x.length === /** * We need this JSDoc comment for affecting ESDoc. * @extends {Ignored} - * @hide true + * @ignore */ export class FromObservable extends Observable { constructor(private ish: ObservableInput, private scheduler?: Scheduler) { diff --git a/src/observable/GenerateObservable.ts b/src/observable/GenerateObservable.ts index 8f59767e02..740e23e9b8 100644 --- a/src/observable/GenerateObservable.ts +++ b/src/observable/GenerateObservable.ts @@ -52,7 +52,7 @@ export interface GenerateOptions extends GenerateBaseOptions { /** * We need this JSDoc comment for affecting ESDoc. * @extends {Ignored} - * @hide true + * @ignore */ export class GenerateObservable extends Observable { constructor(private initialState: S, diff --git a/src/observable/IfObservable.ts b/src/observable/IfObservable.ts index 63d99f3e62..a4efb2d8bc 100644 --- a/src/observable/IfObservable.ts +++ b/src/observable/IfObservable.ts @@ -7,7 +7,7 @@ import { OuterSubscriber } from '../OuterSubscriber'; /** * We need this JSDoc comment for affecting ESDoc. * @extends {Ignored} - * @hide true + * @ignore */ export class IfObservable extends Observable { diff --git a/src/observable/IntervalObservable.ts b/src/observable/IntervalObservable.ts index 8abdd6962c..e8ffd78764 100644 --- a/src/observable/IntervalObservable.ts +++ b/src/observable/IntervalObservable.ts @@ -7,7 +7,7 @@ import { async } from '../scheduler/async'; /** * We need this JSDoc comment for affecting ESDoc. * @extends {Ignored} - * @hide true + * @ignore */ export class IntervalObservable extends Observable { /** diff --git a/src/observable/IteratorObservable.ts b/src/observable/IteratorObservable.ts index 4195965f25..49d53a42a1 100644 --- a/src/observable/IteratorObservable.ts +++ b/src/observable/IteratorObservable.ts @@ -8,7 +8,7 @@ import { Subscriber } from '../Subscriber'; /** * We need this JSDoc comment for affecting ESDoc. * @extends {Ignored} - * @hide true + * @ignore */ export class IteratorObservable extends Observable { private iterator: any; diff --git a/src/observable/NeverObservable.ts b/src/observable/NeverObservable.ts index b0f9259d70..3aa7491665 100644 --- a/src/observable/NeverObservable.ts +++ b/src/observable/NeverObservable.ts @@ -5,7 +5,7 @@ import { noop } from '../util/noop'; /** * We need this JSDoc comment for affecting ESDoc. * @extends {Ignored} - * @hide true + * @ignore */ export class NeverObservable extends Observable { /** diff --git a/src/observable/PairsObservable.ts b/src/observable/PairsObservable.ts index ef99786b63..badd9eb7cc 100644 --- a/src/observable/PairsObservable.ts +++ b/src/observable/PairsObservable.ts @@ -30,7 +30,7 @@ function dispatch(state: PairsContext) { /** * We need this JSDoc comment for affecting ESDoc. * @extends {Ignored} - * @hide true + * @ignore */ export class PairsObservable extends Observable> { private keys: Array; @@ -91,4 +91,4 @@ export class PairsObservable extends Observable> { subscriber.complete(); } } -} \ No newline at end of file +} diff --git a/src/observable/PromiseObservable.ts b/src/observable/PromiseObservable.ts index 9693afaa91..747d8f5682 100644 --- a/src/observable/PromiseObservable.ts +++ b/src/observable/PromiseObservable.ts @@ -7,7 +7,7 @@ import { TeardownLogic } from '../Subscription'; /** * We need this JSDoc comment for affecting ESDoc. * @extends {Ignored} - * @hide true + * @ignore */ export class PromiseObservable extends Observable { diff --git a/src/observable/RangeObservable.ts b/src/observable/RangeObservable.ts index 3788c026d0..93a0d1e1b1 100644 --- a/src/observable/RangeObservable.ts +++ b/src/observable/RangeObservable.ts @@ -6,7 +6,7 @@ import { Subscriber } from '../Subscriber'; /** * We need this JSDoc comment for affecting ESDoc. * @extends {Ignored} - * @hide true + * @ignore */ export class RangeObservable extends Observable { diff --git a/src/observable/ScalarObservable.ts b/src/observable/ScalarObservable.ts index 88b8e3f02d..5afc5af518 100644 --- a/src/observable/ScalarObservable.ts +++ b/src/observable/ScalarObservable.ts @@ -6,7 +6,7 @@ import { TeardownLogic } from '../Subscription'; /** * We need this JSDoc comment for affecting ESDoc. * @extends {Ignored} - * @hide true + * @ignore */ export class ScalarObservable extends Observable { static create(value: T, scheduler?: Scheduler): ScalarObservable { diff --git a/src/observable/SubscribeOnObservable.ts b/src/observable/SubscribeOnObservable.ts index cf003c4c70..023cbca86b 100644 --- a/src/observable/SubscribeOnObservable.ts +++ b/src/observable/SubscribeOnObservable.ts @@ -13,7 +13,7 @@ export interface DispatchArg { /** * We need this JSDoc comment for affecting ESDoc. * @extends {Ignored} - * @hide true + * @ignore */ export class SubscribeOnObservable extends Observable { static create(source: Observable, delay: number = 0, scheduler: Scheduler = asap): Observable { diff --git a/src/observable/TimerObservable.ts b/src/observable/TimerObservable.ts index 12b803ab2e..3ee6c65ff5 100644 --- a/src/observable/TimerObservable.ts +++ b/src/observable/TimerObservable.ts @@ -10,7 +10,7 @@ import { Subscriber } from '../Subscriber'; /** * We need this JSDoc comment for affecting ESDoc. * @extends {Ignored} - * @hide true + * @ignore */ export class TimerObservable extends Observable { diff --git a/src/observable/UsingObservable.ts b/src/observable/UsingObservable.ts index 45a5a39d13..c2688b12cd 100644 --- a/src/observable/UsingObservable.ts +++ b/src/observable/UsingObservable.ts @@ -7,7 +7,7 @@ import { OuterSubscriber } from '../OuterSubscriber'; /** * We need this JSDoc comment for affecting ESDoc. * @extends {Ignored} - * @hide true + * @ignore */ export class UsingObservable extends Observable { @@ -54,4 +54,4 @@ class UsingSubscriber extends OuterSubscriber { this._error(err); } } -} \ No newline at end of file +} diff --git a/src/observable/dom/AjaxObservable.ts b/src/observable/dom/AjaxObservable.ts index 506589ed1d..a66655e871 100644 --- a/src/observable/dom/AjaxObservable.ts +++ b/src/observable/dom/AjaxObservable.ts @@ -94,7 +94,7 @@ export function ajaxGetJSON(url: string, headers?: Object): Observable { /** * We need this JSDoc comment for affecting ESDoc. * @extends {Ignored} - * @hide true + * @ignore */ export class AjaxObservable extends Observable { /** diff --git a/src/observable/dom/WebSocketSubject.ts b/src/observable/dom/WebSocketSubject.ts index 8c4ba943e9..e52635e2cf 100644 --- a/src/observable/dom/WebSocketSubject.ts +++ b/src/observable/dom/WebSocketSubject.ts @@ -23,7 +23,7 @@ export interface WebSocketSubjectConfig { /** * We need this JSDoc comment for affecting ESDoc. * @extends {Ignored} - * @hide true + * @ignore */ export class WebSocketSubject extends AnonymousSubject { diff --git a/tools/custom-esdoc-plugin.js b/tools/custom-esdoc-plugin.js index 36fac63f32..0a0f7ffd44 100644 --- a/tools/custom-esdoc-plugin.js +++ b/tools/custom-esdoc-plugin.js @@ -38,7 +38,6 @@ exports.onHandleTag = function onHandleTag(ev) { var name = getTagValue(tag, '@name'); var isStatic = getTagValue(tag, '@static'); var noImport = getTagValue(tag, '@noimport'); - var isHidden = getTagValue(tag, '@hide'); if (name) { tag.name = name; } @@ -46,10 +45,7 @@ exports.onHandleTag = function onHandleTag(ev) { delete tag.importPath; delete tag.importStyle; } - if (isHidden) { - ev.data.tag[i] = {name: '', longname: ''}; - ev.data.tag[i]['export'] = false; - } else if (owner) { + if (owner && owner === 'Observable') { var ownerLongname = getLongname(ev, owner); tag.kind = 'method'; tag.static = false;