@teambit/component-writer 1.0.225 → 1.0.227
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/artifacts/__bit_junit.xml +1 -1
- package/artifacts/schema.json +29 -135
- package/package.json +10 -10
- package/tsconfig.json +25 -1
- package/dist/component-writer.aspect.d.ts +0 -2
- package/dist/component-writer.d.ts +0 -56
- package/dist/component-writer.main.runtime.d.ts +0 -72
- package/dist/index.d.ts +0 -5
- /package/dist/{preview-1712546198033.js → preview-1712719054377.js} +0 -0
|
@@ -1,4 +1,4 @@
|
|
|
1
1
|
<?xml version="1.0" encoding="UTF-8"?>
|
|
2
2
|
<testsuites tests="0" failures="0" errors="0" skipped="0">
|
|
3
|
-
<testsuite name="teambit.component/component-writer@1.0.
|
|
3
|
+
<testsuite name="teambit.component/component-writer@1.0.227" tests="0" failures="0" errors="0" skipped="0"/>
|
|
4
4
|
</testsuites>
|
package/artifacts/schema.json
CHANGED
|
@@ -48,11 +48,7 @@
|
|
|
48
48
|
"line": 45,
|
|
49
49
|
"character": 24
|
|
50
50
|
},
|
|
51
|
-
"name": "InstallMain"
|
|
52
|
-
"componentId": {
|
|
53
|
-
"scope": "teambit.workspace",
|
|
54
|
-
"name": "install"
|
|
55
|
-
}
|
|
51
|
+
"name": "InstallMain"
|
|
56
52
|
},
|
|
57
53
|
"isOptional": false,
|
|
58
54
|
"isSpread": false
|
|
@@ -72,11 +68,7 @@
|
|
|
72
68
|
"line": 46,
|
|
73
69
|
"character": 23
|
|
74
70
|
},
|
|
75
|
-
"name": "CompilerMain"
|
|
76
|
-
"componentId": {
|
|
77
|
-
"scope": "teambit.compilation",
|
|
78
|
-
"name": "compiler"
|
|
79
|
-
}
|
|
71
|
+
"name": "CompilerMain"
|
|
80
72
|
},
|
|
81
73
|
"isOptional": false,
|
|
82
74
|
"isSpread": false
|
|
@@ -96,11 +88,7 @@
|
|
|
96
88
|
"line": 47,
|
|
97
89
|
"character": 24
|
|
98
90
|
},
|
|
99
|
-
"name": "Workspace"
|
|
100
|
-
"componentId": {
|
|
101
|
-
"scope": "teambit.workspace",
|
|
102
|
-
"name": "workspace"
|
|
103
|
-
}
|
|
91
|
+
"name": "Workspace"
|
|
104
92
|
},
|
|
105
93
|
"isOptional": false,
|
|
106
94
|
"isSpread": false
|
|
@@ -120,11 +108,7 @@
|
|
|
120
108
|
"line": 48,
|
|
121
109
|
"character": 21
|
|
122
110
|
},
|
|
123
|
-
"name": "Logger"
|
|
124
|
-
"componentId": {
|
|
125
|
-
"scope": "teambit.harmony",
|
|
126
|
-
"name": "logger"
|
|
127
|
-
}
|
|
111
|
+
"name": "Logger"
|
|
128
112
|
},
|
|
129
113
|
"isOptional": false,
|
|
130
114
|
"isSpread": false
|
|
@@ -144,11 +128,7 @@
|
|
|
144
128
|
"line": 49,
|
|
145
129
|
"character": 20
|
|
146
130
|
},
|
|
147
|
-
"name": "MoverMain"
|
|
148
|
-
"componentId": {
|
|
149
|
-
"scope": "teambit.component",
|
|
150
|
-
"name": "mover"
|
|
151
|
-
}
|
|
131
|
+
"name": "MoverMain"
|
|
152
132
|
},
|
|
153
133
|
"isOptional": false,
|
|
154
134
|
"isSpread": false
|
|
@@ -168,11 +148,7 @@
|
|
|
168
148
|
"line": 50,
|
|
169
149
|
"character": 26
|
|
170
150
|
},
|
|
171
|
-
"name": "ConfigMergerMain"
|
|
172
|
-
"componentId": {
|
|
173
|
-
"scope": "teambit.workspace",
|
|
174
|
-
"name": "config-merger"
|
|
175
|
-
}
|
|
151
|
+
"name": "ConfigMergerMain"
|
|
176
152
|
},
|
|
177
153
|
"isOptional": false,
|
|
178
154
|
"isSpread": false
|
|
@@ -360,11 +336,7 @@
|
|
|
360
336
|
"line": 292,
|
|
361
337
|
"character": 5
|
|
362
338
|
},
|
|
363
|
-
"name": "InstallMain"
|
|
364
|
-
"componentId": {
|
|
365
|
-
"scope": "teambit.workspace",
|
|
366
|
-
"name": "install"
|
|
367
|
-
}
|
|
339
|
+
"name": "InstallMain"
|
|
368
340
|
},
|
|
369
341
|
{
|
|
370
342
|
"__schema": "TypeRefSchema",
|
|
@@ -373,11 +345,7 @@
|
|
|
373
345
|
"line": 293,
|
|
374
346
|
"character": 5
|
|
375
347
|
},
|
|
376
|
-
"name": "CompilerMain"
|
|
377
|
-
"componentId": {
|
|
378
|
-
"scope": "teambit.compilation",
|
|
379
|
-
"name": "compiler"
|
|
380
|
-
}
|
|
348
|
+
"name": "CompilerMain"
|
|
381
349
|
},
|
|
382
350
|
{
|
|
383
351
|
"__schema": "TypeRefSchema",
|
|
@@ -386,11 +354,7 @@
|
|
|
386
354
|
"line": 294,
|
|
387
355
|
"character": 5
|
|
388
356
|
},
|
|
389
|
-
"name": "LoggerMain"
|
|
390
|
-
"componentId": {
|
|
391
|
-
"scope": "teambit.harmony",
|
|
392
|
-
"name": "logger"
|
|
393
|
-
}
|
|
357
|
+
"name": "LoggerMain"
|
|
394
358
|
},
|
|
395
359
|
{
|
|
396
360
|
"__schema": "TypeRefSchema",
|
|
@@ -399,11 +363,7 @@
|
|
|
399
363
|
"line": 295,
|
|
400
364
|
"character": 5
|
|
401
365
|
},
|
|
402
|
-
"name": "Workspace"
|
|
403
|
-
"componentId": {
|
|
404
|
-
"scope": "teambit.workspace",
|
|
405
|
-
"name": "workspace"
|
|
406
|
-
}
|
|
366
|
+
"name": "Workspace"
|
|
407
367
|
},
|
|
408
368
|
{
|
|
409
369
|
"__schema": "TypeRefSchema",
|
|
@@ -412,11 +372,7 @@
|
|
|
412
372
|
"line": 296,
|
|
413
373
|
"character": 5
|
|
414
374
|
},
|
|
415
|
-
"name": "MoverMain"
|
|
416
|
-
"componentId": {
|
|
417
|
-
"scope": "teambit.component",
|
|
418
|
-
"name": "mover"
|
|
419
|
-
}
|
|
375
|
+
"name": "MoverMain"
|
|
420
376
|
},
|
|
421
377
|
{
|
|
422
378
|
"__schema": "TypeRefSchema",
|
|
@@ -425,11 +381,7 @@
|
|
|
425
381
|
"line": 297,
|
|
426
382
|
"character": 5
|
|
427
383
|
},
|
|
428
|
-
"name": "ConfigMergerMain"
|
|
429
|
-
"componentId": {
|
|
430
|
-
"scope": "teambit.workspace",
|
|
431
|
-
"name": "config-merger"
|
|
432
|
-
}
|
|
384
|
+
"name": "ConfigMergerMain"
|
|
433
385
|
}
|
|
434
386
|
]
|
|
435
387
|
},
|
|
@@ -528,11 +480,7 @@
|
|
|
528
480
|
"line": 40,
|
|
529
481
|
"character": 33
|
|
530
482
|
},
|
|
531
|
-
"name": "WorkspaceConfigUpdateResult"
|
|
532
|
-
"componentId": {
|
|
533
|
-
"scope": "teambit.workspace",
|
|
534
|
-
"name": "config-merger"
|
|
535
|
-
}
|
|
483
|
+
"name": "WorkspaceConfigUpdateResult"
|
|
536
484
|
},
|
|
537
485
|
"isOptional": true
|
|
538
486
|
}
|
|
@@ -572,8 +520,7 @@
|
|
|
572
520
|
"line": 23,
|
|
573
521
|
"character": 15
|
|
574
522
|
},
|
|
575
|
-
"name": "ConsumerComponent"
|
|
576
|
-
"packageName": "@teambit/legacy/dist/consumer/component"
|
|
523
|
+
"name": "ConsumerComponent"
|
|
577
524
|
}
|
|
578
525
|
},
|
|
579
526
|
"isOptional": false
|
|
@@ -954,8 +901,7 @@
|
|
|
954
901
|
"line": 23,
|
|
955
902
|
"character": 15
|
|
956
903
|
},
|
|
957
|
-
"name": "ConsumerComponent"
|
|
958
|
-
"packageName": "@teambit/legacy/dist/consumer/component"
|
|
904
|
+
"name": "ConsumerComponent"
|
|
959
905
|
}
|
|
960
906
|
},
|
|
961
907
|
"isOptional": false
|
|
@@ -1256,11 +1202,7 @@
|
|
|
1256
1202
|
"line": 40,
|
|
1257
1203
|
"character": 33
|
|
1258
1204
|
},
|
|
1259
|
-
"name": "WorkspaceConfigUpdateResult"
|
|
1260
|
-
"componentId": {
|
|
1261
|
-
"scope": "teambit.workspace",
|
|
1262
|
-
"name": "config-merger"
|
|
1263
|
-
}
|
|
1205
|
+
"name": "WorkspaceConfigUpdateResult"
|
|
1264
1206
|
},
|
|
1265
1207
|
"isOptional": true
|
|
1266
1208
|
}
|
|
@@ -1302,11 +1244,7 @@
|
|
|
1302
1244
|
"line": 45,
|
|
1303
1245
|
"character": 24
|
|
1304
1246
|
},
|
|
1305
|
-
"name": "InstallMain"
|
|
1306
|
-
"componentId": {
|
|
1307
|
-
"scope": "teambit.workspace",
|
|
1308
|
-
"name": "install"
|
|
1309
|
-
}
|
|
1247
|
+
"name": "InstallMain"
|
|
1310
1248
|
},
|
|
1311
1249
|
"isOptional": false,
|
|
1312
1250
|
"isSpread": false
|
|
@@ -1326,11 +1264,7 @@
|
|
|
1326
1264
|
"line": 46,
|
|
1327
1265
|
"character": 23
|
|
1328
1266
|
},
|
|
1329
|
-
"name": "CompilerMain"
|
|
1330
|
-
"componentId": {
|
|
1331
|
-
"scope": "teambit.compilation",
|
|
1332
|
-
"name": "compiler"
|
|
1333
|
-
}
|
|
1267
|
+
"name": "CompilerMain"
|
|
1334
1268
|
},
|
|
1335
1269
|
"isOptional": false,
|
|
1336
1270
|
"isSpread": false
|
|
@@ -1350,11 +1284,7 @@
|
|
|
1350
1284
|
"line": 47,
|
|
1351
1285
|
"character": 24
|
|
1352
1286
|
},
|
|
1353
|
-
"name": "Workspace"
|
|
1354
|
-
"componentId": {
|
|
1355
|
-
"scope": "teambit.workspace",
|
|
1356
|
-
"name": "workspace"
|
|
1357
|
-
}
|
|
1287
|
+
"name": "Workspace"
|
|
1358
1288
|
},
|
|
1359
1289
|
"isOptional": false,
|
|
1360
1290
|
"isSpread": false
|
|
@@ -1374,11 +1304,7 @@
|
|
|
1374
1304
|
"line": 48,
|
|
1375
1305
|
"character": 21
|
|
1376
1306
|
},
|
|
1377
|
-
"name": "Logger"
|
|
1378
|
-
"componentId": {
|
|
1379
|
-
"scope": "teambit.harmony",
|
|
1380
|
-
"name": "logger"
|
|
1381
|
-
}
|
|
1307
|
+
"name": "Logger"
|
|
1382
1308
|
},
|
|
1383
1309
|
"isOptional": false,
|
|
1384
1310
|
"isSpread": false
|
|
@@ -1398,11 +1324,7 @@
|
|
|
1398
1324
|
"line": 49,
|
|
1399
1325
|
"character": 20
|
|
1400
1326
|
},
|
|
1401
|
-
"name": "MoverMain"
|
|
1402
|
-
"componentId": {
|
|
1403
|
-
"scope": "teambit.component",
|
|
1404
|
-
"name": "mover"
|
|
1405
|
-
}
|
|
1327
|
+
"name": "MoverMain"
|
|
1406
1328
|
},
|
|
1407
1329
|
"isOptional": false,
|
|
1408
1330
|
"isSpread": false
|
|
@@ -1422,11 +1344,7 @@
|
|
|
1422
1344
|
"line": 50,
|
|
1423
1345
|
"character": 26
|
|
1424
1346
|
},
|
|
1425
|
-
"name": "ConfigMergerMain"
|
|
1426
|
-
"componentId": {
|
|
1427
|
-
"scope": "teambit.workspace",
|
|
1428
|
-
"name": "config-merger"
|
|
1429
|
-
}
|
|
1347
|
+
"name": "ConfigMergerMain"
|
|
1430
1348
|
},
|
|
1431
1349
|
"isOptional": false,
|
|
1432
1350
|
"isSpread": false
|
|
@@ -1614,11 +1532,7 @@
|
|
|
1614
1532
|
"line": 292,
|
|
1615
1533
|
"character": 5
|
|
1616
1534
|
},
|
|
1617
|
-
"name": "InstallMain"
|
|
1618
|
-
"componentId": {
|
|
1619
|
-
"scope": "teambit.workspace",
|
|
1620
|
-
"name": "install"
|
|
1621
|
-
}
|
|
1535
|
+
"name": "InstallMain"
|
|
1622
1536
|
},
|
|
1623
1537
|
{
|
|
1624
1538
|
"__schema": "TypeRefSchema",
|
|
@@ -1627,11 +1541,7 @@
|
|
|
1627
1541
|
"line": 293,
|
|
1628
1542
|
"character": 5
|
|
1629
1543
|
},
|
|
1630
|
-
"name": "CompilerMain"
|
|
1631
|
-
"componentId": {
|
|
1632
|
-
"scope": "teambit.compilation",
|
|
1633
|
-
"name": "compiler"
|
|
1634
|
-
}
|
|
1544
|
+
"name": "CompilerMain"
|
|
1635
1545
|
},
|
|
1636
1546
|
{
|
|
1637
1547
|
"__schema": "TypeRefSchema",
|
|
@@ -1640,11 +1550,7 @@
|
|
|
1640
1550
|
"line": 294,
|
|
1641
1551
|
"character": 5
|
|
1642
1552
|
},
|
|
1643
|
-
"name": "LoggerMain"
|
|
1644
|
-
"componentId": {
|
|
1645
|
-
"scope": "teambit.harmony",
|
|
1646
|
-
"name": "logger"
|
|
1647
|
-
}
|
|
1553
|
+
"name": "LoggerMain"
|
|
1648
1554
|
},
|
|
1649
1555
|
{
|
|
1650
1556
|
"__schema": "TypeRefSchema",
|
|
@@ -1653,11 +1559,7 @@
|
|
|
1653
1559
|
"line": 295,
|
|
1654
1560
|
"character": 5
|
|
1655
1561
|
},
|
|
1656
|
-
"name": "Workspace"
|
|
1657
|
-
"componentId": {
|
|
1658
|
-
"scope": "teambit.workspace",
|
|
1659
|
-
"name": "workspace"
|
|
1660
|
-
}
|
|
1562
|
+
"name": "Workspace"
|
|
1661
1563
|
},
|
|
1662
1564
|
{
|
|
1663
1565
|
"__schema": "TypeRefSchema",
|
|
@@ -1666,11 +1568,7 @@
|
|
|
1666
1568
|
"line": 296,
|
|
1667
1569
|
"character": 5
|
|
1668
1570
|
},
|
|
1669
|
-
"name": "MoverMain"
|
|
1670
|
-
"componentId": {
|
|
1671
|
-
"scope": "teambit.component",
|
|
1672
|
-
"name": "mover"
|
|
1673
|
-
}
|
|
1571
|
+
"name": "MoverMain"
|
|
1674
1572
|
},
|
|
1675
1573
|
{
|
|
1676
1574
|
"__schema": "TypeRefSchema",
|
|
@@ -1679,11 +1577,7 @@
|
|
|
1679
1577
|
"line": 297,
|
|
1680
1578
|
"character": 5
|
|
1681
1579
|
},
|
|
1682
|
-
"name": "ConfigMergerMain"
|
|
1683
|
-
"componentId": {
|
|
1684
|
-
"scope": "teambit.workspace",
|
|
1685
|
-
"name": "config-merger"
|
|
1686
|
-
}
|
|
1580
|
+
"name": "ConfigMergerMain"
|
|
1687
1581
|
}
|
|
1688
1582
|
]
|
|
1689
1583
|
},
|
|
@@ -1846,7 +1740,7 @@
|
|
|
1846
1740
|
"componentId": {
|
|
1847
1741
|
"scope": "teambit.component",
|
|
1848
1742
|
"name": "component-writer",
|
|
1849
|
-
"version": "1.0.
|
|
1743
|
+
"version": "1.0.227"
|
|
1850
1744
|
},
|
|
1851
1745
|
"taggedModuleExports": []
|
|
1852
1746
|
}
|
package/package.json
CHANGED
|
@@ -1,12 +1,12 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@teambit/component-writer",
|
|
3
|
-
"version": "1.0.
|
|
3
|
+
"version": "1.0.227",
|
|
4
4
|
"homepage": "https://bit.cloud/teambit/component/component-writer",
|
|
5
5
|
"main": "dist/index.js",
|
|
6
6
|
"componentId": {
|
|
7
7
|
"scope": "teambit.component",
|
|
8
8
|
"name": "component-writer",
|
|
9
|
-
"version": "1.0.
|
|
9
|
+
"version": "1.0.227"
|
|
10
10
|
},
|
|
11
11
|
"dependencies": {
|
|
12
12
|
"fs-extra": "10.0.0",
|
|
@@ -16,20 +16,20 @@
|
|
|
16
16
|
"@teambit/bit-error": "0.0.404",
|
|
17
17
|
"@teambit/component-id": "1.2.0",
|
|
18
18
|
"@teambit/component-version": "1.0.3",
|
|
19
|
-
"@teambit/cli": "0.0.
|
|
20
|
-
"@teambit/compiler": "1.0.
|
|
21
|
-
"@teambit/config-merger": "0.0.
|
|
22
|
-
"@teambit/install": "1.0.
|
|
23
|
-
"@teambit/logger": "0.0.
|
|
24
|
-
"@teambit/mover": "1.0.
|
|
25
|
-
"@teambit/workspace": "1.0.
|
|
19
|
+
"@teambit/cli": "0.0.860",
|
|
20
|
+
"@teambit/compiler": "1.0.227",
|
|
21
|
+
"@teambit/config-merger": "0.0.94",
|
|
22
|
+
"@teambit/install": "1.0.227",
|
|
23
|
+
"@teambit/logger": "0.0.953",
|
|
24
|
+
"@teambit/mover": "1.0.227",
|
|
25
|
+
"@teambit/workspace": "1.0.227"
|
|
26
26
|
},
|
|
27
27
|
"devDependencies": {
|
|
28
28
|
"@types/fs-extra": "9.0.7",
|
|
29
29
|
"@types/lodash": "4.14.165",
|
|
30
30
|
"@types/mocha": "9.1.0",
|
|
31
31
|
"chai": "4.3.0",
|
|
32
|
-
"@teambit/harmony.envs.core-aspect-env": "0.0.
|
|
32
|
+
"@teambit/harmony.envs.core-aspect-env": "0.0.30"
|
|
33
33
|
},
|
|
34
34
|
"peerDependencies": {
|
|
35
35
|
"@teambit/legacy": "1.0.624"
|
package/tsconfig.json
CHANGED
|
@@ -20,7 +20,8 @@
|
|
|
20
20
|
"emitDeclarationOnly": true,
|
|
21
21
|
"strict": true,
|
|
22
22
|
"strictPropertyInitialization": false,
|
|
23
|
-
"noImplicitAny": false
|
|
23
|
+
"noImplicitAny": false,
|
|
24
|
+
"composite": true
|
|
24
25
|
},
|
|
25
26
|
"exclude": [
|
|
26
27
|
"artifacts",
|
|
@@ -35,5 +36,28 @@
|
|
|
35
36
|
"include": [
|
|
36
37
|
"**/*",
|
|
37
38
|
"**/*.json"
|
|
39
|
+
],
|
|
40
|
+
"references": [
|
|
41
|
+
{
|
|
42
|
+
"path": "/home/circleci/Library/Caches/Bit/capsules/8891be5ad3d35bfc38b9cd90c0e05b598a5a55af/teambit.harmony_cli@0.0.860"
|
|
43
|
+
},
|
|
44
|
+
{
|
|
45
|
+
"path": "/home/circleci/Library/Caches/Bit/capsules/8891be5ad3d35bfc38b9cd90c0e05b598a5a55af/teambit.compilation_compiler@1.0.227"
|
|
46
|
+
},
|
|
47
|
+
{
|
|
48
|
+
"path": "/home/circleci/Library/Caches/Bit/capsules/8891be5ad3d35bfc38b9cd90c0e05b598a5a55af/teambit.workspace_config-merger@0.0.94"
|
|
49
|
+
},
|
|
50
|
+
{
|
|
51
|
+
"path": "/home/circleci/Library/Caches/Bit/capsules/8891be5ad3d35bfc38b9cd90c0e05b598a5a55af/teambit.workspace_install@1.0.227"
|
|
52
|
+
},
|
|
53
|
+
{
|
|
54
|
+
"path": "/home/circleci/Library/Caches/Bit/capsules/8891be5ad3d35bfc38b9cd90c0e05b598a5a55af/teambit.harmony_logger@0.0.953"
|
|
55
|
+
},
|
|
56
|
+
{
|
|
57
|
+
"path": "/home/circleci/Library/Caches/Bit/capsules/8891be5ad3d35bfc38b9cd90c0e05b598a5a55af/teambit.component_mover@1.0.227"
|
|
58
|
+
},
|
|
59
|
+
{
|
|
60
|
+
"path": "/home/circleci/Library/Caches/Bit/capsules/8891be5ad3d35bfc38b9cd90c0e05b598a5a55af/teambit.workspace_workspace@1.0.227"
|
|
61
|
+
}
|
|
38
62
|
]
|
|
39
63
|
}
|
|
@@ -1,56 +0,0 @@
|
|
|
1
|
-
import { ComponentIdList } from '@teambit/component-id';
|
|
2
|
-
import { Scope } from '@teambit/legacy/dist/scope';
|
|
3
|
-
import { PathLinuxRelative } from '@teambit/legacy/dist/utils/path';
|
|
4
|
-
import BitMap from '@teambit/legacy/dist/consumer/bit-map/bit-map';
|
|
5
|
-
import ComponentMap from '@teambit/legacy/dist/consumer/bit-map/component-map';
|
|
6
|
-
import Component from '@teambit/legacy/dist/consumer/component/consumer-component';
|
|
7
|
-
import Consumer from '@teambit/legacy/dist/consumer/consumer';
|
|
8
|
-
import { Workspace } from '@teambit/workspace';
|
|
9
|
-
export type ComponentWriterProps = {
|
|
10
|
-
component: Component;
|
|
11
|
-
writeToPath: PathLinuxRelative;
|
|
12
|
-
writeConfig?: boolean;
|
|
13
|
-
writePackageJson?: boolean;
|
|
14
|
-
override?: boolean;
|
|
15
|
-
isolated?: boolean;
|
|
16
|
-
workspace: Workspace;
|
|
17
|
-
scope?: Scope | undefined;
|
|
18
|
-
bitMap: BitMap;
|
|
19
|
-
ignoreBitDependencies?: boolean | ComponentIdList;
|
|
20
|
-
deleteBitDirContent?: boolean;
|
|
21
|
-
existingComponentMap?: ComponentMap;
|
|
22
|
-
skipUpdatingBitMap?: boolean;
|
|
23
|
-
};
|
|
24
|
-
export default class ComponentWriter {
|
|
25
|
-
component: Component;
|
|
26
|
-
writeToPath: PathLinuxRelative;
|
|
27
|
-
writeConfig?: boolean;
|
|
28
|
-
writePackageJson?: boolean;
|
|
29
|
-
override: boolean;
|
|
30
|
-
isolated?: boolean;
|
|
31
|
-
consumer: Consumer | undefined;
|
|
32
|
-
workspace: Workspace;
|
|
33
|
-
scope?: Scope | undefined;
|
|
34
|
-
bitMap: BitMap;
|
|
35
|
-
ignoreBitDependencies: boolean | ComponentIdList;
|
|
36
|
-
deleteBitDirContent: boolean | undefined;
|
|
37
|
-
existingComponentMap: ComponentMap | undefined;
|
|
38
|
-
skipUpdatingBitMap?: boolean;
|
|
39
|
-
constructor({ component, writeToPath, writeConfig, writePackageJson, override, isolated, workspace, scope, bitMap, ignoreBitDependencies, deleteBitDirContent, existingComponentMap, skipUpdatingBitMap, }: ComponentWriterProps);
|
|
40
|
-
/**
|
|
41
|
-
* write the component to the filesystem and update .bitmap with the details.
|
|
42
|
-
*
|
|
43
|
-
* bitMap gets updated before writing the files to the filesystem, because as part of writing the
|
|
44
|
-
* package-json file, the componentMap is needed to be stored with the updated version.
|
|
45
|
-
*
|
|
46
|
-
* when a component is not new, write the files according to the paths in .bitmap.
|
|
47
|
-
*/
|
|
48
|
-
write(): Promise<Component>;
|
|
49
|
-
populateComponentsFilesToWrite(): Promise<Component>;
|
|
50
|
-
private throwForImportingLegacyIntoHarmony;
|
|
51
|
-
populateFilesToWriteToComponentDir(): Promise<void>;
|
|
52
|
-
addComponentToBitMap(rootDir: string): Promise<ComponentMap>;
|
|
53
|
-
private replaceSnapWithTagIfNeeded;
|
|
54
|
-
_updateComponentRootPathAccordingToBitMap(): void;
|
|
55
|
-
_updateFilesBasePaths(): void;
|
|
56
|
-
}
|
|
@@ -1,72 +0,0 @@
|
|
|
1
|
-
import { CompilerMain } from '@teambit/compiler';
|
|
2
|
-
import { InstallMain } from '@teambit/install';
|
|
3
|
-
import { Logger, LoggerMain } from '@teambit/logger';
|
|
4
|
-
import { Workspace } from '@teambit/workspace';
|
|
5
|
-
import { MoverMain } from '@teambit/mover';
|
|
6
|
-
import ConsumerComponent from '@teambit/legacy/dist/consumer/component';
|
|
7
|
-
import { ConfigMergerMain, WorkspaceConfigUpdateResult } from '@teambit/config-merger';
|
|
8
|
-
import Consumer from '@teambit/legacy/dist/consumer/consumer';
|
|
9
|
-
export interface ManyComponentsWriterParams {
|
|
10
|
-
components: ConsumerComponent[];
|
|
11
|
-
writeToPath?: string;
|
|
12
|
-
throwForExistingDir?: boolean;
|
|
13
|
-
writeConfig?: boolean;
|
|
14
|
-
skipDependencyInstallation?: boolean;
|
|
15
|
-
verbose?: boolean;
|
|
16
|
-
resetConfig?: boolean;
|
|
17
|
-
skipWritingToFs?: boolean;
|
|
18
|
-
skipUpdatingBitMap?: boolean;
|
|
19
|
-
skipWriteConfigFiles?: boolean;
|
|
20
|
-
reasonForBitmapChange?: string;
|
|
21
|
-
shouldUpdateWorkspaceConfig?: boolean;
|
|
22
|
-
}
|
|
23
|
-
export type ComponentWriterResults = {
|
|
24
|
-
installationError?: Error;
|
|
25
|
-
compilationError?: Error;
|
|
26
|
-
workspaceConfigUpdateResult?: WorkspaceConfigUpdateResult;
|
|
27
|
-
};
|
|
28
|
-
export declare class ComponentWriterMain {
|
|
29
|
-
private installer;
|
|
30
|
-
private compiler;
|
|
31
|
-
private workspace;
|
|
32
|
-
private logger;
|
|
33
|
-
private mover;
|
|
34
|
-
private configMerge;
|
|
35
|
-
constructor(installer: InstallMain, compiler: CompilerMain, workspace: Workspace, logger: Logger, mover: MoverMain, configMerge: ConfigMergerMain);
|
|
36
|
-
get consumer(): Consumer;
|
|
37
|
-
writeMany(opts: ManyComponentsWriterParams): Promise<ComponentWriterResults>;
|
|
38
|
-
private installPackagesGracefully;
|
|
39
|
-
private compileGracefully;
|
|
40
|
-
private persistComponentsData;
|
|
41
|
-
private populateComponentsFilesToWrite;
|
|
42
|
-
/**
|
|
43
|
-
* this started to be an issue once same-name different-scope is supported.
|
|
44
|
-
* by default, the component-dir consist of the scope-name part of the scope-id, without the owner part.
|
|
45
|
-
* as a result, it's possible that multiple components have the same name, same scope-name but different owner.
|
|
46
|
-
* e.g. org1.ui/button and org2.ui/button. the component-dir for both is "ui/button".
|
|
47
|
-
* in this case, we try to prefix the component-dir with the owner-name and if not possible, just increment it (ui/button_1)
|
|
48
|
-
*/
|
|
49
|
-
private fixDirsIfEqual;
|
|
50
|
-
/**
|
|
51
|
-
* e.g. [bar, bar/foo] => [bar_1, bar/foo]
|
|
52
|
-
* otherwise, the bar/foo component will be saved inside "bar" component.
|
|
53
|
-
* in case bar_1 is taken, increment to bar_2 until the name is available.
|
|
54
|
-
*/
|
|
55
|
-
private fixDirsIfNested;
|
|
56
|
-
private getWriteParamsOfOneComponent;
|
|
57
|
-
private moveComponentsIfNeeded;
|
|
58
|
-
private throwErrorWhenDirectoryNotEmpty;
|
|
59
|
-
static slots: never[];
|
|
60
|
-
static dependencies: import("@teambit/harmony").Aspect[];
|
|
61
|
-
static runtime: import("@teambit/harmony").RuntimeDefinition;
|
|
62
|
-
static provider([install, compiler, loggerMain, workspace, mover, configMerger]: [
|
|
63
|
-
InstallMain,
|
|
64
|
-
CompilerMain,
|
|
65
|
-
LoggerMain,
|
|
66
|
-
Workspace,
|
|
67
|
-
MoverMain,
|
|
68
|
-
ConfigMergerMain
|
|
69
|
-
]): Promise<ComponentWriterMain>;
|
|
70
|
-
}
|
|
71
|
-
export default ComponentWriterMain;
|
|
72
|
-
export declare function incrementPathRecursively(p: string, allPaths: string[]): string;
|
package/dist/index.d.ts
DELETED
|
@@ -1,5 +0,0 @@
|
|
|
1
|
-
import { ComponentWriterAspect } from './component-writer.aspect';
|
|
2
|
-
export type { ComponentWriterMain, ComponentWriterResults, ManyComponentsWriterParams, } from './component-writer.main.runtime';
|
|
3
|
-
export { incrementPathRecursively } from './component-writer.main.runtime';
|
|
4
|
-
export default ComponentWriterAspect;
|
|
5
|
-
export { ComponentWriterAspect };
|
|
File without changes
|