Skip to content

Commit 50f726f

Browse files
committed
Merge branch 'feat/another-overhaul' into feat/internal-overhaul
2 parents da93f90 + 3e7eaa4 commit 50f726f

39 files changed

+503
-1587
lines changed

.trunk/trunk.yaml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,10 @@
11
version: 0.1
22
cli:
3-
version: 1.14.2
3+
version: 1.15.0
44
plugins:
55
sources:
66
- id: trunk
7-
ref: v1.1.0
7+
ref: v1.2.1
88
uri: https://github.com/trunk-io/plugins
99
lint:
1010
threshold:

docs/docs/api-reference/PlexusActionHelpers.mdx

Lines changed: 0 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,6 @@ The action helpers for a defined plexus action
1212
- [.onCatch(handler, useGlobal)](#PlexusActionHelpers+onCatch)
1313
- [.runErrorHandlers()](#PlexusActionHelpers+runErrorHandlers)
1414
- [.ignoreInit()](#PlexusActionHelpers+ignoreInit)
15-
- [.batch(fn)](#PlexusActionHelpers+batch)
1615

1716
<a name='PlexusActionHelpers+catchError'></a>
1817

@@ -51,16 +50,3 @@ The action helpers for a defined plexus action
5150
### .ignoreInit()
5251

5352
<p>Ignore the default halt for preActions</p>
54-
55-
<a name='PlexusActionHelpers+batch'></a>
56-
57-
### .batch(fn)
58-
59-
<p>
60-
Run a function. During that function's execution, any state changes will be
61-
batched and only applied once the function has finished.
62-
</p>
63-
64-
| Param | Description |
65-
| ----- | ------------------------------------- |
66-
| fn | <p>The function to run in a batch</p> |

docs/docs/api-reference/Scope.mdx

Lines changed: 0 additions & 26 deletions
Original file line numberDiff line numberDiff line change
@@ -11,8 +11,6 @@ Create a new PlexusJS plugin
1111
- [.computed(item)](#Scope+computed)
1212
- [.event()](#Scope+event)
1313
- [.collection(config)](#Scope+collection)
14-
- [.action(fn)](#Scope+action)
15-
- [.batchAction(fn)](#Scope+batchAction)
1614
- [.batch(fn)](#Scope+batch)
1715
- [.preaction(fn)](#Scope+preaction)
1816

@@ -60,30 +58,6 @@ Create a new PlexusJS plugin
6058
| ------ | ------------------------------------------- |
6159
| config | <p>The configuration for the collection</p> |
6260

63-
<a name='Scope+action'></a>
64-
65-
### .action(fn) ⇒
66-
67-
<p>Generate a Plexus Action</p>
68-
69-
**Returns**: <p>The intended return value of fn, or null if an error is caught</p>
70-
71-
| Param | Description |
72-
| ----- | ---------------------------------------- |
73-
| fn | <p>The Plexus action function to run</p> |
74-
75-
<a name='Scope+batchAction'></a>
76-
77-
### .batchAction(fn) ⇒
78-
79-
<p>Generate a Plexus Action</p>
80-
81-
**Returns**: <p>The intended return value of fn, or null if an error is caught</p>
82-
83-
| Param | Description |
84-
| ----- | ---------------------------------------- |
85-
| fn | <p>The Plexus action function to run</p> |
86-
8761
<a name='Scope+batch'></a>
8862

8963
### .batch(fn)

docs/docs/api-reference/action.mdx

Lines changed: 0 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -17,15 +17,3 @@ Generate a Plexus Action
1717
| Param | Description |
1818
| ----- | ---------------------------------------- |
1919
| fn | <p>The Plexus action function to run</p> |
20-
21-
<a name='Scope+action'></a>
22-
23-
## .action(fn) ⇒
24-
25-
<p>Generate a Plexus Action</p>
26-
27-
**Returns**: <p>The intended return value of fn, or null if an error is caught</p>
28-
29-
| Param | Description |
30-
| ----- | ---------------------------------------- |
31-
| fn | <p>The Plexus action function to run</p> |

docs/docs/api-reference/batch.mdx

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -19,9 +19,9 @@ Run a function. During that function's execution, any state changes will be batc
1919
| ----- | ------------------------------------- |
2020
| fn | <p>The function to run in a batch</p> |
2121

22-
<a name='PlexusActionHelpers+batch'></a>
22+
<a name='batch'></a>
2323

24-
## .batch(fn)
24+
## batch(fn)
2525

2626
<p>
2727
Run a function. During that function's execution, any state changes will be

docs/docs/api-reference/batchAction.mdx

Lines changed: 0 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -17,15 +17,3 @@ Generate a Plexus Action
1717
| Param | Description |
1818
| ----- | ---------------------------------------- |
1919
| fn | <p>The Plexus action function to run</p> |
20-
21-
<a name='Scope+batchAction'></a>
22-
23-
## .batchAction(fn) ⇒
24-
25-
<p>Generate a Plexus Action</p>
26-
27-
**Returns**: <p>The intended return value of fn, or null if an error is caught</p>
28-
29-
| Param | Description |
30-
| ----- | ---------------------------------------- |
31-
| fn | <p>The Plexus action function to run</p> |
Lines changed: 34 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,34 @@
1+
---
2+
title: onCatch
3+
---
4+
5+
[![view on npm](http://img.shields.io/npm/v/@plexusjs/core.svg)](https://www.npmjs.org/package/@plexusjs/core)
6+
7+
Add a new error handler for this action. This will catch any errors that occur during the execution of this action and prevent a crash.
8+
9+
<a name='onCatch'></a>
10+
11+
## onCatch(handler?)
12+
13+
<p>
14+
Add a new error handler for this action. This will catch any errors that occur
15+
during the execution of this action and prevent a crash.
16+
</p>
17+
18+
| Param | Description |
19+
| -------- | ---------------------------------------------------------------------------------- |
20+
| handler? | <p>A function that will be called when an error occurs; omit to fail silently.</p> |
21+
22+
<a name='PlexusActionHelpers+onCatch'></a>
23+
24+
## .onCatch(handler, useGlobal)
25+
26+
<p>
27+
Add a new error handler for this action. This will catch any errors that occur
28+
during the execution of this action and prevent a crash.
29+
</p>
30+
31+
| Param | Default | Description |
32+
| --------- | ----------------- | ---------------------------------------------------------------------------------- |
33+
| handler | | <p>A function that will be called when an error occurs; omit to fail silently.</p> |
34+
| useGlobal | <code>true</code> | <p>Should the global error handler be used? (default: true)</p> |

jest.config.ts

Lines changed: 0 additions & 13 deletions
This file was deleted.

lerna.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
{
2-
"version": "1.10.3",
2+
"version": "1.10.4",
33
"npmClient": "yarn",
44
"useNx": true,
55
"packages": ["packages/*"],

package.json

Lines changed: 2 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@
2020
"bootstrap": "lerna bootstrap --use-workspaces",
2121
"build": "lerna run build",
2222
"postbuild": "yarn docs:generate:ref",
23-
"dev": "lerna run build && lerna watch -- lerna run build --since",
23+
"dev": "lerna run build && lerna watch -- lerna run build --scope=$LERNA_PACKAGE_NAME",
2424
"prereleaseOnly": "pinst --disable && echo '🚀 Publishing...'",
2525
"release-canary": "lerna run build && lerna publish --preid canary --no-private --yes --force-publish --canary",
2626
"release-stable": "lerna run build && lerna publish --preid canary --no-private --yes --force-publish",
@@ -41,7 +41,6 @@
4141
"@testing-library/react": "^14.0.0",
4242
"@trunkio/launcher": "^1.2.3",
4343
"@types/fs-readdir-recursive": "^1.1.0",
44-
"@types/jest": "^27.4.0",
4544
"@types/jsdoc-to-markdown": "^7.0.3",
4645
"@types/node": "^18.11.11",
4746
"@types/react": "^18.0.17",
@@ -50,11 +49,9 @@
5049
"@types/recursive-readdir": "^2.2.1",
5150
"@vitejs/plugin-react": "^4.0.4",
5251
"@vitest/ui": "^0.34.2",
53-
"babel-jest": "^27.4.6",
5452
"chalk": "4",
5553
"fs-readdir-recursive": "^1.1.0",
5654
"happy-dom": "^10.10.4",
57-
"jest": "^27.4.7",
5855
"jsdoc-babel": "^0.5.0",
5956
"jsdoc-to-markdown": "^8.0.0",
6057
"jsdom": "^20.0.1",
@@ -68,9 +65,8 @@
6865
"react-dom": "^18",
6966
"react-test-renderer": "^18.2.0",
7067
"recursive-readdir": "^2.2.3",
71-
"ts-jest": "^27.1.2",
7268
"ts-node": "^10.9.1",
73-
"typescript": "^5.1.6",
69+
"typescript": "^5.2.2",
7470
"vite": "^4.4.9",
7571
"vitest": "^0.34.2",
7672
"yargs": "^17.4.1"

0 commit comments

Comments
 (0)