Skip to content

Commit

Permalink
finalizing gulp tasks
Browse files Browse the repository at this point in the history
  • Loading branch information
nmccready committed Aug 27, 2019
1 parent 5f1dd17 commit d043c98
Show file tree
Hide file tree
Showing 11 changed files with 59 additions and 49 deletions.
4 changes: 2 additions & 2 deletions docs/api/interfaces/_actions_.innerbaseactions.md
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@

**setRef**: *function*

*Defined in [actions.ts:10](https://github.com/nmccready/use-global-hook/blob/6416474/src/actions.ts#L10)*
*Defined in [actions.ts:10](https://github.com/nmccready/use-global-hook/blob/5f1dd17/src/actions.ts#L10)*

#### Type declaration:

Expand All @@ -45,7 +45,7 @@ ___

**setState**: *function*

*Defined in [actions.ts:9](https://github.com/nmccready/use-global-hook/blob/6416474/src/actions.ts#L9)*
*Defined in [actions.ts:9](https://github.com/nmccready/use-global-hook/blob/5f1dd17/src/actions.ts#L9)*

#### Type declaration:

Expand Down
4 changes: 2 additions & 2 deletions docs/api/interfaces/_actions_.outerbaseactions.md
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@

**setRef**: *function*

*Defined in [actions.ts:5](https://github.com/nmccready/use-global-hook/blob/6416474/src/actions.ts#L5)*
*Defined in [actions.ts:5](https://github.com/nmccready/use-global-hook/blob/5f1dd17/src/actions.ts#L5)*

#### Type declaration:

Expand All @@ -44,7 +44,7 @@ ___

**setState**: *function*

*Defined in [actions.ts:4](https://github.com/nmccready/use-global-hook/blob/6416474/src/actions.ts#L4)*
*Defined in [actions.ts:4](https://github.com/nmccready/use-global-hook/blob/5f1dd17/src/actions.ts#L4)*

#### Type declaration:

Expand Down
4 changes: 2 additions & 2 deletions docs/api/interfaces/_index_.reactlib.md
Original file line number Diff line number Diff line change
Expand Up @@ -21,12 +21,12 @@

**useEffect**: *[UseEffect](../modules/_index_.md#useeffect)*

*Defined in [index.ts:7](https://github.com/nmccready/use-global-hook/blob/6416474/src/index.ts#L7)*
*Defined in [index.ts:7](https://github.com/nmccready/use-global-hook/blob/5f1dd17/src/index.ts#L7)*

___

### useState

**useState**: *[UseState](../modules/_index_.md#usestate)*

*Defined in [index.ts:8](https://github.com/nmccready/use-global-hook/blob/6416474/src/index.ts#L8)*
*Defined in [index.ts:8](https://github.com/nmccready/use-global-hook/blob/5f1dd17/src/index.ts#L8)*
10 changes: 5 additions & 5 deletions docs/api/interfaces/_index_.store.md
Original file line number Diff line number Diff line change
Expand Up @@ -30,36 +30,36 @@

**actions**: *OuterA*

*Defined in [index.ts:47](https://github.com/nmccready/use-global-hook/blob/6416474/src/index.ts#L47)*
*Defined in [index.ts:47](https://github.com/nmccready/use-global-hook/blob/5f1dd17/src/index.ts#L47)*

___

### listeners

**listeners**: *Dispatch‹unknown›[]*

*Defined in [index.ts:49](https://github.com/nmccready/use-global-hook/blob/6416474/src/index.ts#L49)*
*Defined in [index.ts:49](https://github.com/nmccready/use-global-hook/blob/5f1dd17/src/index.ts#L49)*

___

### setRef

**setRef**: *[SetRefFn](../modules/_index_.md#setreffn)‹T›*

*Defined in [index.ts:46](https://github.com/nmccready/use-global-hook/blob/6416474/src/index.ts#L46)*
*Defined in [index.ts:46](https://github.com/nmccready/use-global-hook/blob/5f1dd17/src/index.ts#L46)*

___

### setState

**setState**: *[SetStateFn](../modules/_index_.md#setstatefn)‹T›*

*Defined in [index.ts:45](https://github.com/nmccready/use-global-hook/blob/6416474/src/index.ts#L45)*
*Defined in [index.ts:45](https://github.com/nmccready/use-global-hook/blob/5f1dd17/src/index.ts#L45)*

___

### state

**state**: *T*

*Defined in [index.ts:48](https://github.com/nmccready/use-global-hook/blob/6416474/src/index.ts#L48)*
*Defined in [index.ts:48](https://github.com/nmccready/use-global-hook/blob/5f1dd17/src/index.ts#L48)*
10 changes: 5 additions & 5 deletions docs/api/interfaces/_index_.usestoreprops.md
Original file line number Diff line number Diff line change
Expand Up @@ -34,23 +34,23 @@

**React**: *[ReactLib](_index_.reactlib.md)*

*Defined in [index.ts:28](https://github.com/nmccready/use-global-hook/blob/6416474/src/index.ts#L28)*
*Defined in [index.ts:28](https://github.com/nmccready/use-global-hook/blob/5f1dd17/src/index.ts#L28)*

___

### `Optional` actions

**actions**? : *InnerA | [InnerBaseActions](_actions_.innerbaseactions.md)‹T›*

*Defined in [index.ts:30](https://github.com/nmccready/use-global-hook/blob/6416474/src/index.ts#L30)*
*Defined in [index.ts:30](https://github.com/nmccready/use-global-hook/blob/5f1dd17/src/index.ts#L30)*

___

### `Optional` hookWork

**hookWork**? : *function*

*Defined in [index.ts:32](https://github.com/nmccready/use-global-hook/blob/6416474/src/index.ts#L32)*
*Defined in [index.ts:32](https://github.com/nmccready/use-global-hook/blob/5f1dd17/src/index.ts#L32)*

#### Type declaration:

Expand All @@ -62,12 +62,12 @@ ___

**initialState**? : *T*

*Defined in [index.ts:29](https://github.com/nmccready/use-global-hook/blob/6416474/src/index.ts#L29)*
*Defined in [index.ts:29](https://github.com/nmccready/use-global-hook/blob/5f1dd17/src/index.ts#L29)*

___

### `Optional` initializer

**initializer**? : *[Initializer](../modules/_index_.md#initializer)‹T, OuterA›*

*Defined in [index.ts:31](https://github.com/nmccready/use-global-hook/blob/6416474/src/index.ts#L31)*
*Defined in [index.ts:31](https://github.com/nmccready/use-global-hook/blob/5f1dd17/src/index.ts#L31)*
10 changes: 5 additions & 5 deletions docs/api/modules/_actions_.md
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@

**setRef**<**T**>(`store`: [Store](../interfaces/_index_.store.md)‹T, [OuterBaseActions](../interfaces/_actions_.outerbaseactions.md)‹T››, `newState`: T, `doDigest?`: boolean): *void*

*Defined in [actions.ts:21](https://github.com/nmccready/use-global-hook/blob/6416474/src/actions.ts#L21)*
*Defined in [actions.ts:21](https://github.com/nmccready/use-global-hook/blob/5f1dd17/src/actions.ts#L21)*

**Type parameters:**

Expand All @@ -48,7 +48,7 @@ ___

**setState**<**T**>(`store`: [Store](../interfaces/_index_.store.md)‹T, [OuterBaseActions](../interfaces/_actions_.outerbaseactions.md)‹T››, `newState`: T, `doDigest?`: boolean): *void*

*Defined in [actions.ts:13](https://github.com/nmccready/use-global-hook/blob/6416474/src/actions.ts#L13)*
*Defined in [actions.ts:13](https://github.com/nmccready/use-global-hook/blob/5f1dd17/src/actions.ts#L13)*

**Type parameters:**

Expand All @@ -70,16 +70,16 @@ Name | Type |

### **actions**: *object*

*Defined in [actions.ts:29](https://github.com/nmccready/use-global-hook/blob/6416474/src/actions.ts#L29)*
*Defined in [actions.ts:29](https://github.com/nmccready/use-global-hook/blob/5f1dd17/src/actions.ts#L29)*

### setRef

**setRef**: *[setRef]()*

*Defined in [actions.ts:29](https://github.com/nmccready/use-global-hook/blob/6416474/src/actions.ts#L29)*
*Defined in [actions.ts:29](https://github.com/nmccready/use-global-hook/blob/5f1dd17/src/actions.ts#L29)*

### setState

**setState**: *[setState]()*

*Defined in [actions.ts:29](https://github.com/nmccready/use-global-hook/blob/6416474/src/actions.ts#L29)*
*Defined in [actions.ts:29](https://github.com/nmccready/use-global-hook/blob/5f1dd17/src/actions.ts#L29)*
28 changes: 14 additions & 14 deletions docs/api/modules/_index_.md
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@

Ƭ **AssociateActionsFn**: *function*

*Defined in [index.ts:18](https://github.com/nmccready/use-global-hook/blob/6416474/src/index.ts#L18)*
*Defined in [index.ts:18](https://github.com/nmccready/use-global-hook/blob/5f1dd17/src/index.ts#L18)*

#### Type declaration:

Expand All @@ -63,7 +63,7 @@ ___

Ƭ **HookWork**: *function*

*Defined in [index.ts:74](https://github.com/nmccready/use-global-hook/blob/6416474/src/index.ts#L74)*
*Defined in [index.ts:74](https://github.com/nmccready/use-global-hook/blob/5f1dd17/src/index.ts#L74)*

#### Type declaration:

Expand All @@ -75,7 +75,7 @@ ___

Ƭ **Initializer**: *function*

*Defined in [index.ts:20](https://github.com/nmccready/use-global-hook/blob/6416474/src/index.ts#L20)*
*Defined in [index.ts:20](https://github.com/nmccready/use-global-hook/blob/5f1dd17/src/index.ts#L20)*

#### Type declaration:

Expand All @@ -93,7 +93,7 @@ ___

Ƭ **SetRefFn**: *function*

*Defined in [index.ts:14](https://github.com/nmccready/use-global-hook/blob/6416474/src/index.ts#L14)*
*Defined in [index.ts:14](https://github.com/nmccready/use-global-hook/blob/5f1dd17/src/index.ts#L14)*

#### Type declaration:

Expand All @@ -112,7 +112,7 @@ ___

Ƭ **SetStateFn**: *function*

*Defined in [index.ts:12](https://github.com/nmccready/use-global-hook/blob/6416474/src/index.ts#L12)*
*Defined in [index.ts:12](https://github.com/nmccready/use-global-hook/blob/5f1dd17/src/index.ts#L12)*

#### Type declaration:

Expand All @@ -132,7 +132,7 @@ ___

Ƭ **UseCustomFn**: *function*

*Defined in [index.ts:16](https://github.com/nmccready/use-global-hook/blob/6416474/src/index.ts#L16)*
*Defined in [index.ts:16](https://github.com/nmccready/use-global-hook/blob/5f1dd17/src/index.ts#L16)*

#### Type declaration:

Expand All @@ -150,7 +150,7 @@ ___

Ƭ **UseEffect**: *function*

*Defined in [index.ts:4](https://github.com/nmccready/use-global-hook/blob/6416474/src/index.ts#L4)*
*Defined in [index.ts:4](https://github.com/nmccready/use-global-hook/blob/5f1dd17/src/index.ts#L4)*

#### Type declaration:

Expand All @@ -169,7 +169,7 @@ ___

Ƭ **UseState**: *function*

*Defined in [index.ts:5](https://github.com/nmccready/use-global-hook/blob/6416474/src/index.ts#L5)*
*Defined in [index.ts:5](https://github.com/nmccready/use-global-hook/blob/5f1dd17/src/index.ts#L5)*

#### Type declaration:

Expand All @@ -191,7 +191,7 @@ ___

Ƭ **UseStoreFn**: *function*

*Defined in [index.ts:35](https://github.com/nmccready/use-global-hook/blob/6416474/src/index.ts#L35)*
*Defined in [index.ts:35](https://github.com/nmccready/use-global-hook/blob/5f1dd17/src/index.ts#L35)*

#### Type declaration:

Expand Down Expand Up @@ -221,7 +221,7 @@ Name | Type |

**associateActions**<**T**, **InnerA**, **OuterA**>(`store`: [Store](../interfaces/_index_.store.md)‹T, OuterA›, `actions`: InnerA): *OuterA*

*Defined in [index.ts:110](https://github.com/nmccready/use-global-hook/blob/6416474/src/index.ts#L110)*
*Defined in [index.ts:110](https://github.com/nmccready/use-global-hook/blob/5f1dd17/src/index.ts#L110)*

**Type parameters:**

Expand All @@ -246,7 +246,7 @@ ___

**setRef**<**T**, **A**>(`this`: [Store](../interfaces/_index_.store.md)‹T, A›, `newState`: T, `doDigest?`: boolean): *void*

*Defined in [index.ts:70](https://github.com/nmccready/use-global-hook/blob/6416474/src/index.ts#L70)*
*Defined in [index.ts:70](https://github.com/nmccready/use-global-hook/blob/5f1dd17/src/index.ts#L70)*

**Type parameters:**

Expand All @@ -270,7 +270,7 @@ ___

**setState**<**T**, **A**>(`this`: [Store](../interfaces/_index_.store.md)‹T, A›, `newState`: T, `isRef?`: boolean, `doDigest`: boolean): *void*

*Defined in [index.ts:52](https://github.com/nmccready/use-global-hook/blob/6416474/src/index.ts#L52)*
*Defined in [index.ts:52](https://github.com/nmccready/use-global-hook/blob/5f1dd17/src/index.ts#L52)*

**Type parameters:**

Expand All @@ -295,7 +295,7 @@ ___

**useCustom**<**T**, **A**, **WorkR**>(`this`: [Store](../interfaces/_index_.store.md)‹T, A›, `React`: [ReactLib](../interfaces/_index_.reactlib.md), `hookWork?`: [HookWork](_index_.md#hookwork)‹WorkR›): *[T, A]*

*Defined in [index.ts:76](https://github.com/nmccready/use-global-hook/blob/6416474/src/index.ts#L76)*
*Defined in [index.ts:76](https://github.com/nmccready/use-global-hook/blob/5f1dd17/src/index.ts#L76)*

**Type parameters:**

Expand All @@ -321,7 +321,7 @@ ___

**useStore**<**T**, **InnerA**, **OuterA**, **WorkR**>(`__namedParameters`: object): *function*

*Defined in [index.ts:129](https://github.com/nmccready/use-global-hook/blob/6416474/src/index.ts#L129)*
*Defined in [index.ts:129](https://github.com/nmccready/use-global-hook/blob/5f1dd17/src/index.ts#L129)*

**Type parameters:**

Expand Down
2 changes: 1 addition & 1 deletion docs/bundle.js

Large diffs are not rendered by default.

20 changes: 8 additions & 12 deletions gulpfile.ts
Original file line number Diff line number Diff line change
Expand Up @@ -71,12 +71,12 @@ const publishMainWebsite = () => run('yarn website', { verbosity: 3 }).exec();

const publishApiWebsite = () => run('yarn publish:api:website', { verbosity: 3 }).exec();

gulp.task('docs:website', gulp.series('docs:clean', setupWebsiteMarkdown, runDevWebsite));
gulp.task('docs:website', gulp.series('docs:clean', setupWebsiteMarkdown));

gulp.task(
'docs:website:dev',
gulp.series('docs:website', () => {
gulp.watch(docsSource, gulp.series('docs:website'));
gulp.series('docs:website', runDevWebsite, () => {
gulp.watch(docsSource, gulp.series('docs:website', runDevWebsite));
})
);

Expand All @@ -93,14 +93,10 @@ gulp.task(
gulp.task('default', gulp.series('clean', 'build'));

gulp.task(
'publish',
gulp.series(
'default',
gulp.parallel(
'build',
gulp.series('docs:api:website', publishApiWebsite),
'docs:api:markdown',
gulp.series('docs:website', publishMainWebsite)
)
'publish:websites',
gulp.parallel(
gulp.series('docs:api:website', publishApiWebsite),
'docs:api:markdown',
gulp.series('docs:website', publishMainWebsite)
)
);
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@
"preversion": "yarn build",
"website": "yarn x0 build docs/website",
"website:dev": "yarn gulp docs:website:dev",
"publish:api:website": "cd ../use-global-hook-api-website/ && git push origin"
"publish:api:website": "scripts/publishApiWebsite.sh"
},
"devDependencies": {
"@compositor/logo": "^1.4.0",
Expand Down
14 changes: 14 additions & 0 deletions scripts/publishApiWebsite.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
#!/bin/sh
set -e
set -o pipefail

FROM_VERSION=`jq -r .version package.json`
cd ../use-global-hook-api-website/

if [ -n "$(git status --porcelain)" ]; then
git commit -am "syncing with use-global-hook version: ${FROM_VERSION}"
git push origin
else
exit 0;
fi

0 comments on commit d043c98

Please sign in to comment.