react-component-snapshot 0.0.15 → 0.0.17
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/package.json +4 -4
- package/src/fiber/index.d.mts +1 -1
- package/src/index.d.mts +1 -1
- package/.publish/README.md +0 -20
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "react-component-snapshot",
|
|
3
|
-
"version": "0.0.
|
|
3
|
+
"version": "0.0.17",
|
|
4
4
|
"description": "Transform a React component to match its snapshot in Jest",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"react",
|
|
@@ -31,15 +31,15 @@
|
|
|
31
31
|
},
|
|
32
32
|
"dependencies": {
|
|
33
33
|
"debug": "^4.4.0",
|
|
34
|
-
"react-component-name": "^0.0.
|
|
34
|
+
"react-component-name": "^0.0.8"
|
|
35
35
|
},
|
|
36
36
|
"devDependencies": {
|
|
37
37
|
"@babel/core": "^7.26.10",
|
|
38
38
|
"@babel/eslint-parser": "^7.27.0",
|
|
39
39
|
"@babel/preset-env": "^7.26.9",
|
|
40
40
|
"@babel/preset-react": "^7.26.3",
|
|
41
|
-
"@sequencemedia/eslint-config-standard": "^0.2.
|
|
42
|
-
"@sequencemedia/eslint-config-typescript": "^0.1.
|
|
41
|
+
"@sequencemedia/eslint-config-standard": "^0.2.47",
|
|
42
|
+
"@sequencemedia/eslint-config-typescript": "^0.1.69",
|
|
43
43
|
"@testing-library/jest-dom": "^6.6.3",
|
|
44
44
|
"@testing-library/react": "^16.2.0",
|
|
45
45
|
"@types/debug": "^4.1.12",
|
package/src/fiber/index.d.mts
CHANGED
|
@@ -3,7 +3,7 @@ import type React from 'react'
|
|
|
3
3
|
type FiberNode = ReactComponentSnapshotTypes.FiberNode
|
|
4
4
|
type StateNodeType = Element | Text | React.Component<any, any>
|
|
5
5
|
|
|
6
|
-
export function getStateNodeFiber (stateNode: StateNodeType)
|
|
6
|
+
export function getStateNodeFiber (stateNode: StateNodeType): Record<PropertyKey, unknown> | null
|
|
7
7
|
|
|
8
8
|
export function getStateNodeProps (stateNode: StateNodeType): Record<PropertyKey, unknown> | null
|
|
9
9
|
|
package/src/index.d.mts
CHANGED
|
@@ -12,7 +12,7 @@ export function toSnapshotFromRender (render: RenderType): Record<PropertyKey, u
|
|
|
12
12
|
|
|
13
13
|
export function toSnapshotFromContainerElement (containerElement: Element): Record<PropertyKey, unknown> | null
|
|
14
14
|
|
|
15
|
-
export function toSnapshotFromComponentElement (componentElement?: Element | null)
|
|
15
|
+
export function toSnapshotFromComponentElement (componentElement?: Element | null): Record<PropertyKey, unknown> | null
|
|
16
16
|
|
|
17
17
|
export function snapshotOf (element?: Element | null): Record<PropertyKey, unknown> | null
|
|
18
18
|
|
package/.publish/README.md
DELETED
|
@@ -1,20 +0,0 @@
|
|
|
1
|
-
# Publish to NPM
|
|
2
|
-
|
|
3
|
-
For CircleCI or the shell
|
|
4
|
-
|
|
5
|
-
If you need an _authentication token_ to publish then you should resolve that before executing this script
|
|
6
|
-
|
|
7
|
-
```bash
|
|
8
|
-
echo ".publish/publish.sh" >> .npmignore
|
|
9
|
-
git clone https://github.com/modernpoacher/publish.git .publish
|
|
10
|
-
.publish/publish.sh
|
|
11
|
-
```
|
|
12
|
-
|
|
13
|
-
A Gist with the same content as `publish.sh` may need an additional step
|
|
14
|
-
|
|
15
|
-
```bash
|
|
16
|
-
echo ".publish/publish.sh" >> .npmignore
|
|
17
|
-
git clone https://gist.github.com/efd85e2b8da1ee830dd637f134994a9d.git .publish
|
|
18
|
-
chmod +x .publish/publish.sh
|
|
19
|
-
.publish/publish.sh
|
|
20
|
-
```
|