File tree Expand file tree Collapse file tree 5 files changed +32
-4
lines changed
packages/jest-transformer Expand file tree Collapse file tree 5 files changed +32
-4
lines changed Original file line number Diff line number Diff line change 88 "always",
99 [
1010 "json-map-keys",
11- "jest",
1211 "loader",
1312 "rollup"
13+ "jest-transformer",
1414 ]
1515 ]
1616 }
File renamed without changes.
Original file line number Diff line number Diff line change 11# json-map-keys-jest
22
3- > Jest transformer to replace json values with the key path.
3+ Jest transformer to replace json values with the keys path.
4+
5+ Example:
6+
7+ ``` json
8+ {
9+ "a" : {
10+ "b" : " Text Note"
11+ }
12+ }
13+ ```
14+
15+ Will generate
16+
17+ ``` json
18+ {
19+ "a" : {
20+ "b" : " a.b"
21+ }
22+ }
23+ ```
24+
25+ ## Install
26+
27+ ``` sh
28+ npm install json-map-keys-jest --save-dev
29+ ```
30+
31+ ## Usage
432
533``` js
634/** @type {import('jest').Config} */
File renamed without changes.
Original file line number Diff line number Diff line change 22 "name" : " json-map-keys-jest" ,
33 "version" : " 1.0.0-beta.1" ,
44 "description" : " Jest transformer to replace json values with the key path." ,
5- "homepage" : " https://github.com/tiagoporto/json-map-keys/tree/main/packages/json-map-keys- jest#readme" ,
5+ "homepage" : " https://github.com/tiagoporto/json-map-keys/tree/main/packages/jest-transformer #readme" ,
66 "keywords" : [
77 " jest" ,
88 " transformer" ,
1414 "repository" : {
1515 "type" : " git" ,
1616 "url" : " https://github.com/tiagoporto/json-map-keys.git" ,
17- "directory" : " packages/json-map-keys- jest"
17+ "directory" : " packages/jest-transformer "
1818 },
1919 "funding" : " https://github.com/sponsors/tiagoporto" ,
2020 "license" : " MIT" ,
You can’t perform that action at this time.
0 commit comments