pre-mortem 0.1.5 → 0.1.7

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/src/ui.ts DELETED
@@ -1,634 +0,0 @@
1
- import { BlockType, BLOCK_DEFINITIONS } from './blocks';
2
- import { GameState } from './gamestate';
3
-
4
- export interface UIOptions {
5
- onSpawn: (type: BlockType) => void;
6
- onRotate: () => void;
7
- gameState: GameState;
8
- }
9
-
10
- export class UIManager {
11
- private container: HTMLElement;
12
- private options: UIOptions;
13
- private hudElement!: HTMLElement;
14
-
15
- constructor(container: HTMLElement, options: UIOptions) {
16
- this.container = container;
17
- this.options = options;
18
- this.initStyles();
19
- this.createHUD();
20
- this.createControls();
21
- this.createLegend();
22
- this.createSystemButtons();
23
-
24
- // Subscribe to updates
25
- this.options.gameState.subscribe((event) => {
26
- this.updateHUD();
27
- if (event === 'penalty') {
28
- this.showToast(`-${this.options.gameState.lastPenaltyReason}`, 'danger');
29
- } else if (event?.startsWith('funding:')) {
30
- const amount = event.split(':')[1];
31
- this.showToast(`+$${parseInt(amount).toLocaleString()} Series Funding!`, 'info');
32
- }
33
- });
34
- this.updateHUD(); // Initial render
35
- }
36
-
37
- private initStyles() {
38
- const style = document.createElement('style');
39
- style.textContent = `
40
- .uj-hud {
41
- position: absolute;
42
- top: 20px; /* Restored to top */
43
- right: 20px;
44
- color: #fff;
45
- font-family: 'Inter', sans-serif;
46
- text-align: right;
47
- pointer-events: none;
48
- z-index: 100;
49
- }
50
- /* ... existing styles ... */
51
- .uj-sys-btn {
52
- background: rgba(255,255,255,0.1);
53
- border: 1px solid rgba(255,255,255,0.3);
54
- color: #fff;
55
- padding: 6px 10px;
56
- border-radius: 4px;
57
- cursor: pointer;
58
- font-size: 11px; /* Slightly smaller to be discreet */
59
- font-family: 'Inter', sans-serif;
60
- transition: background 0.2s;
61
- pointer-events: auto;
62
- }
63
- .uj-sys-btn:hover { background: rgba(255,255,255,0.2); }
64
- .uj-sys-container {
65
- position: absolute;
66
- bottom: 20px; /* Moved to bottom */
67
- left: 20px; /* Moved to left */
68
- display: flex;
69
- gap: 10px;
70
- z-index: 200;
71
- opacity: 0.6; /* Make them even less conspicuous */
72
- transition: opacity 0.2s;
73
- }
74
- .uj-sys-container:hover { opacity: 1; }
75
- .uj-stat-label {
76
- font-size: 12px;
77
- color: #888;
78
- text-transform: uppercase;
79
- }
80
- .uj-stat-value {
81
- font-size: 20px;
82
- font-weight: bold;
83
- margin-bottom: 10px;
84
- }
85
- .uj-stat-value.danger {
86
- color: #ff4444;
87
- }
88
- .uj-controls {
89
- position: absolute;
90
- bottom: 20px;
91
- right: 20px; /* Aligned with HUD */
92
- display: flex;
93
- flex-direction: column; /* Stack vertically for cleaner look on right side? Or Keep horizontal? */
94
- /* User said "move right". Sidebar layout might be better. */
95
- gap: 20px;
96
- z-index: 100;
97
- align-items: flex-end; /* Align right */
98
- }
99
- .uj-btn {
100
- padding: 16px 0; /* Changed padding to vertical only, width handles horizontal */
101
- width: 220px; /* Fixed width for equality */
102
- font-family: 'Inter', sans-serif;
103
- font-weight: bold;
104
- border: none;
105
- border-radius: 8px;
106
- cursor: pointer;
107
- text-transform: uppercase;
108
- font-size: 16px;
109
- box-shadow: 0 4px 6px rgba(0,0,0,0.3);
110
- transition: transform 0.1s;
111
- text-align: center; /* Ensure centered text */
112
- }
113
- .uj-btn:active {
114
- transform: scale(0.95);
115
- }
116
- .uj-btn-solid {
117
- background: #555;
118
- color: #fff;
119
- border-bottom: 4px solid #333;
120
- }
121
- .uj-btn-hype {
122
- background: #FF00FF;
123
- color: #fff;
124
- border-bottom: 4px solid #cc00cc;
125
- animation: pulse 2s infinite;
126
- }
127
- .uj-btn-rotate {
128
- background: #0077ff;
129
- color: #fff;
130
- border-bottom: 4px solid #0055aa;
131
- padding: 16px 20px;
132
- }
133
- .uj-btn-rotate.vertical {
134
- background: #00AAFF;
135
- transform: translateY(-2px);
136
- }
137
- @keyframes pulse {
138
- 0% { box-shadow: 0 0 0 0 rgba(255, 0, 255, 0.7); }
139
- 70% { box-shadow: 0 0 0 10px rgba(255, 0, 255, 0); }
140
- 100% { box-shadow: 0 0 0 0 rgba(255, 0, 255, 0); }
141
- }
142
- .uj-overlay-logo {
143
- position: absolute;
144
- top: 20px;
145
- left: 20px;
146
- max-width: 150px;
147
- z-index: 100;
148
- pointer-events: none;
149
- }
150
- .uj-legend {
151
- position: absolute;
152
- top: 80px;
153
- left: 20px;
154
- width: 240px;
155
- z-index: 90;
156
- font-family: 'Inter', sans-serif;
157
- color: white;
158
- background: rgba(0,0,0,0.6);
159
- padding: 12px;
160
- border-radius: 8px;
161
- backdrop-filter: blur(6px);
162
- border: 1px solid rgba(255,255,255,0.1);
163
- }
164
- .uj-legend-item {
165
- display: flex;
166
- align-items: center;
167
- margin-bottom: 12px;
168
- }
169
- .uj-swatch {
170
- width: 20px;
171
- height: 20px;
172
- margin-right: 10px;
173
- border: 1px solid white;
174
- }
175
- .uj-swatch.solid { background: #555; }
176
- .uj-swatch.hype { background: #FF00FF; }
177
- .uj-legend-text { font-size: 12px; line-height: 1.4; }
178
- .uj-legend-note { margin-top: 10px; opacity: 0.7; font-size: 11px; }
179
- .uj-legend-mini {
180
- display: flex;
181
- align-items: center;
182
- gap: 6px;
183
- font-size: 10px;
184
- color: #ddd;
185
- }
186
- .uj-crisis-overlay {
187
- position: absolute;
188
- top: 0; left: 0; width: 100%; height: 100%;
189
- pointer-events: none;
190
- display: flex;
191
- flex-direction: column;
192
- align-items: center;
193
- justify-content: center;
194
- z-index: 400;
195
- font-family: 'Inter', sans-serif;
196
- background: rgba(255, 0, 0, 0);
197
- transition: background 0.3s;
198
- }
199
- .uj-crisis-overlay.active {
200
- background: rgba(255, 0, 0, 0.2);
201
- animation: flash-red 1s infinite;
202
- }
203
- @keyframes flash-red {
204
- 0%, 100% { background: rgba(255,0,0,0.1); }
205
- 50% { background: rgba(255,0,0,0.3); }
206
- }
207
- .uj-crisis-box {
208
- background: #ff4444;
209
- color: white;
210
- padding: 20px 40px;
211
- border-radius: 12px;
212
- box-shadow: 0 0 20px rgba(0,0,0,0.5);
213
- text-align: center;
214
- transform: scale(0.8);
215
- opacity: 0;
216
- transition: all 0.5s cubic-bezier(0.175, 0.885, 0.32, 1.275);
217
- }
218
- .uj-crisis-box.visible {
219
- transform: scale(1);
220
- opacity: 1;
221
- }
222
- .uj-crisis-shout {
223
- font-size: 32px;
224
- font-weight: 900;
225
- margin-bottom: 5px;
226
- text-transform: uppercase;
227
- }
228
- .uj-crisis-desc {
229
- font-size: 18px;
230
- opacity: 0.9;
231
- }
232
- `;
233
- document.head.appendChild(style);
234
- }
235
-
236
- private createControls() {
237
- const controls = document.createElement('div');
238
- controls.className = 'uj-controls';
239
-
240
- const btnSolid = document.createElement('button');
241
- btnSolid.className = 'uj-btn uj-btn-solid';
242
- btnSolid.innerText = 'Build Solid\n(Costs $5k)';
243
- btnSolid.onclick = () => this.options.onSpawn(BlockType.BOOTSTRAP);
244
-
245
- const btnHype = document.createElement('button');
246
- btnHype.className = 'uj-btn uj-btn-hype';
247
- btnHype.innerText = 'Hype Up\n(Grants $75k)';
248
- btnHype.onclick = () => this.options.onSpawn(BlockType.VC);
249
-
250
- controls.appendChild(btnSolid);
251
- controls.appendChild(btnHype);
252
- this.container.appendChild(controls);
253
- }
254
-
255
- private createSystemButtons() {
256
- const container = document.createElement('div');
257
- container.className = 'uj-sys-container';
258
-
259
- const btnPause = document.createElement('button');
260
- btnPause.className = 'uj-sys-btn';
261
- btnPause.innerText = '⏸ PAUSE';
262
- btnPause.id = 'uj-btn-pause'; // Add ID for updating
263
- btnPause.onclick = () => {
264
- const wasPlaying = this.options.gameState.isPlaying();
265
- this.options.gameState.togglePause();
266
- btnPause.innerText = !wasPlaying ? '⏸ PAUSE' : '▶ RESUME';
267
- };
268
-
269
- const btnReset = document.createElement('button');
270
- btnReset.className = 'uj-sys-btn';
271
- btnReset.innerText = '↻ RESET';
272
- btnReset.onclick = () => window.location.reload();
273
-
274
- container.appendChild(btnPause);
275
- container.appendChild(btnReset);
276
- this.container.appendChild(container);
277
- }
278
-
279
- private createLegend() {
280
- const legend = document.createElement('div');
281
- legend.className = 'uj-legend';
282
- legend.innerHTML = `
283
- <div style="margin-bottom: 8px; border-bottom: 1px solid rgba(255,255,255,0.1); padding-bottom: 6px;">
284
- <strong style="color: #00ff7f; font-size: 14px;">MISSION</strong>
285
- <div class="uj-legend-text">
286
- 1. Reach <strong>$1 Billion</strong> Valuation.<br>
287
- 2. Don't run out of <strong>Runway</strong>.<br>
288
- <small style="opacity:0.7">Burn Rate increases with Stage!</small>
289
- </div>
290
- </div>
291
-
292
- <div style="margin-bottom: 12px;">
293
- <div class="uj-legend-item">
294
- <div class="uj-swatch solid"></div>
295
- <div class="uj-legend-text">
296
- <strong>Build Solid</strong><br>
297
- High Friction. Good Foundation.<br>
298
- <span style="color:#ffaaaa">Costs $5k. Low Value.</span>
299
- </div>
300
- </div>
301
- <div class="uj-legend-item">
302
- <div class="uj-swatch hype"></div>
303
- <div class="uj-legend-text">
304
- <strong>Hype Up</strong><br>
305
- Distorted Shape. Unstable.<br>
306
- <span style="color:#aaffaa">Grants $75k. High Value.</span>
307
- </div>
308
- </div>
309
- </div>
310
-
311
- <!-- Toxic Employees Section -->
312
- <div style="margin-bottom: 8px; border-top: 1px solid rgba(255,255,255,0.1); padding-top: 6px;">
313
- <strong style="color: #ff4444; font-size: 13px;">TOXIC (Risk: 1/15)</strong>
314
- <div style="display: grid; grid-template-columns: 1fr 1fr; gap: 8px; margin-top: 5px;">
315
- <div class="uj-legend-mini">
316
- <img src="./slacker.png" style="width: 30px; height: auto;">
317
- <span>Slacker</span>
318
- </div>
319
- <div class="uj-legend-mini">
320
- <img src="./control-freak.png" style="width: 30px; height: auto;">
321
- <span>Control Freak</span>
322
- </div>
323
- <div class="uj-legend-mini">
324
- <img src="./prima-donna.png" style="width: 30px; height: auto;">
325
- <span>Prima Donna</span>
326
- </div>
327
- <div class="uj-legend-mini">
328
- <img src="./quet-quitter.png" style="width: 30px; height: auto;">
329
- <span>Quiet Quitter</span>
330
- </div>
331
- <div class="uj-legend-mini">
332
- <img src="./slack-spammer.png" style="width: 30px; height: auto;">
333
- <span>Spammer</span>
334
- </div>
335
- </div>
336
- <div class="uj-legend-note" style="color: #ffaaaa; margin-top: 5px;">
337
- $0 Val. Heavy. Annoying.
338
- </div>
339
- </div>
340
- <div class="uj-legend-note" style="font-size: 10px; line-height: 1.3;">
341
- <strong style="font-size: 11px;">STRATEGY:</strong><br>
342
- • <strong>Hype-Hole</strong>: High Hype = Zero stability. Organization & code collapse.<br>
343
- • <strong>Solid-Sink</strong>: Pure solid = Runway burn. No growth velocity.<br>
344
- <span style="color: #00ff7f; opacity: 0.9;"><em>Balance foundation with noise.</em></span>
345
- </div>
346
-
347
- <div class="uj-legend-note" style="margin-top: 8px;">
348
- <strong>RULES:</strong><br>
349
- - Blocks only vest inside <strong>Dashed Zone</strong>.<br>
350
- - Crossing <strong>Red Line</strong> = Penalty.<br>
351
- - Press <strong>'R'</strong> to rotate.
352
- </div>
353
-
354
- <!-- Chaos Events Description -->
355
- <div style="margin-top: 8px; border-top: 1px solid rgba(255,255,255,0.1); padding-top: 6px;">
356
- <strong style="color: #ffaa00; font-size: 13px;">CHAOS EVENTS</strong>
357
- <div style="font-size: 11px; color: #ccc; line-height: 1.4; margin-top: 4px;">
358
- • <strong>Strategic Pivot</strong>: Gravity shifts.<br>
359
- • <strong>The Big Reorg</strong>: Zero friction.<br>
360
- • <strong>Legacy Deprecation</strong>: Ghost API.<br>
361
- • <strong>Feature Creep</strong>: Codescale 1.2x.<br>
362
- • <strong>Viral Spike</strong>: Trafficequake.
363
- </div>
364
- </div>
365
-
366
- <button id="uj-view-labels" style="
367
- margin-top: 15px;
368
- width: 100%;
369
- background: rgba(255,255,255,0.1);
370
- border: 1px solid rgba(255,255,255,0.3);
371
- color: #ccc;
372
- border-radius: 4px;
373
- padding: 6px 8px;
374
- cursor: pointer;
375
- font-size: 11px;
376
- transition: background 0.2s;">
377
- View Label Dictionary
378
- </button>
379
- `;
380
- this.container.appendChild(legend);
381
-
382
- document.getElementById('uj-view-labels')?.addEventListener('click', () => {
383
- this.showGlossary();
384
- });
385
- }
386
-
387
- private showGlossary() {
388
- if (document.getElementById('uj-glossary')) return;
389
-
390
- // Pause game
391
- const wasPlaying = this.options.gameState.isPlaying();
392
- if (wasPlaying) {
393
- this.options.gameState.setPaused(true);
394
- const pauseBtn = document.getElementById('uj-btn-pause');
395
- if (pauseBtn) pauseBtn.innerText = '▶ RESUME';
396
- }
397
-
398
- const overlay = document.createElement('div');
399
- overlay.id = 'uj-glossary';
400
- overlay.style.cssText = `
401
- position: absolute;
402
- top: 0; left: 0; width: 100%; height: 100%;
403
- background: rgba(0,0,0,0.9);
404
- color: white;
405
- display: flex;
406
- flex-direction: column;
407
- align-items: center;
408
- justify-content: center;
409
- z-index: 300;
410
- font-family: 'Inter', sans-serif;
411
- `;
412
-
413
- overlay.innerHTML = `
414
- <div style="background: #222; padding: 40px; border-radius: 12px; max-width: 800px; width: 90%; max-height: 80vh; overflow-y: auto; position: relative;">
415
- <button id="uj-glossary-close" style="position: absolute; top: 10px; right: 10px; background: none; border: none; color: white; font-size: 24px; cursor: pointer;">&times;</button>
416
- <h2 style="text-align: center; margin-bottom: 30px;">Startup Lingo Dictionary</h2>
417
- <div style="display: flex; gap: 40px;">
418
- <div style="flex: 1;">
419
- <h3 style="color: #aaa; border-bottom: 2px solid #555; padding-bottom: 10px;">Build Solid (The Work)</h3>
420
- <ul id="uj-solid-list" style="list-style: none; padding: 0; color: #ccc; line-height: 1.6;"></ul>
421
- </div>
422
- <div style="flex: 1;">
423
- <h3 style="color: #FF00FF; border-bottom: 2px solid #cc00cc; padding-bottom: 10px;">Hype Up (The Noise)</h3>
424
- <ul id="uj-hype-list" style="list-style: none; padding: 0; color: #ffccff; line-height: 1.6;"></ul>
425
- </div>
426
- </div>
427
- </div>
428
- `;
429
-
430
- this.container.appendChild(overlay);
431
- this.populateGlossaryLists();
432
-
433
- const close = () => {
434
- overlay.remove();
435
- if (wasPlaying) {
436
- this.options.gameState.setPaused(false);
437
- const pauseBtn = document.getElementById('uj-btn-pause');
438
- if (pauseBtn) pauseBtn.innerText = '⏸ PAUSE';
439
- }
440
- };
441
-
442
- document.getElementById('uj-glossary-close')!.onclick = close;
443
-
444
- // Close on background click
445
- overlay.onclick = (e) => {
446
- if (e.target === overlay) close();
447
- }
448
- }
449
-
450
- private populateGlossaryLists() {
451
- const solidList = document.getElementById('uj-solid-list');
452
- const hypeList = document.getElementById('uj-hype-list');
453
-
454
- if (solidList && hypeList) {
455
- BLOCK_DEFINITIONS[BlockType.BOOTSTRAP].possibleLabels?.forEach(label => {
456
- const li = document.createElement('li');
457
- li.textContent = label;
458
- solidList.appendChild(li);
459
- });
460
-
461
- BLOCK_DEFINITIONS[BlockType.VC].possibleLabels?.forEach(label => {
462
- const li = document.createElement('li');
463
- li.textContent = label;
464
- hypeList.appendChild(li);
465
- });
466
- }
467
- }
468
-
469
- private createHUD() {
470
- this.hudElement = document.createElement('div');
471
- this.hudElement.className = 'uj-hud';
472
- this.container.appendChild(this.hudElement);
473
- }
474
-
475
- private updateHUD() {
476
- const state = this.options.gameState;
477
-
478
- const moneyFormatter = new Intl.NumberFormat('en-US', {
479
- style: 'currency',
480
- currency: 'USD',
481
- maximumFractionDigits: 0,
482
- });
483
- const compactFormatter = new Intl.NumberFormat('en-US', {
484
- style: 'currency',
485
- currency: 'USD',
486
- notation: 'compact',
487
- maximumFractionDigits: 1,
488
- });
489
-
490
- const isBankrupt = state.isBankrupt();
491
- const runwayClass = isBankrupt ? 'uj-stat-value danger' : 'uj-stat-value';
492
-
493
- const nextThreshold = state.getNextStageThreshold();
494
- const nextStageText = nextThreshold > 0 ? `<small style="font-size:12px; opacity:0.7">Next: ${compactFormatter.format(nextThreshold)}</small>` : '';
495
-
496
- this.hudElement.innerHTML = `
497
- <div class="uj-stat-label">Stage</div>
498
- <div class="uj-stat-value">${state.stage}</div>
499
-
500
- <div class="uj-stat-label">Valuation</div>
501
- <div class="uj-stat-value" style="color: #00ff7f">
502
- ${moneyFormatter.format(state.valuation)}<br>
503
- ${nextStageText}
504
- </div>
505
-
506
- <div class="uj-stat-label">Runway</div>
507
- <div class="${runwayClass}">${moneyFormatter.format(state.runway)}</div>
508
- `;
509
-
510
- if (state.status !== 'playing') {
511
- this.showGameOver(state.status, state.valuation);
512
- }
513
- }
514
-
515
- private showToast(message: string, type: 'info' | 'danger' = 'info') {
516
- const toast = document.createElement('div');
517
- toast.innerText = message;
518
- toast.style.cssText = `
519
- position: absolute;
520
- top: 100px;
521
- left: 50%;
522
- transform: translateX(-50%);
523
- background: ${type === 'danger' ? 'rgba(255, 68, 68, 0.9)' : 'rgba(0, 0, 0, 0.8)'};
524
- color: white;
525
- padding: 10px 20px;
526
- border-radius: 20px;
527
- font-family: 'Inter', sans-serif;
528
- font-weight: bold;
529
- z-index: 500;
530
- animation: fadeUp 2s forwards;
531
- white-space: nowrap;
532
- `;
533
-
534
- this.container.appendChild(toast);
535
- setTimeout(() => {
536
- toast.style.transition = 'opacity 0.5s';
537
- toast.style.opacity = '0';
538
- setTimeout(() => toast.remove(), 500);
539
- }, 2000);
540
- }
541
-
542
- private showGameOver(status: string, valuation: number) {
543
- if (document.getElementById('uj-gameover')) return;
544
-
545
- const overlay = document.createElement('div');
546
- overlay.id = 'uj-gameover';
547
- overlay.style.cssText = `
548
- position: absolute;
549
- top: 0; left: 0; width: 100%; height: 100%;
550
- background: rgba(0,0,0,0.85);
551
- color: white;
552
- display: flex;
553
- flex-direction: column;
554
- align-items: center;
555
- justify-content: center;
556
- z-index: 200;
557
- font-family: 'Inter', sans-serif;
558
- `;
559
-
560
- let title = '';
561
- let message = '';
562
- let color = '#fff';
563
-
564
- switch (status) {
565
- case 'bankrupt':
566
- title = 'HONEST POOR';
567
- message = 'You ran out of runway. The market did not love you.';
568
- color = '#ff4444';
569
- break;
570
- case 'collapsed':
571
- title = 'SCANDAL!';
572
- message = 'Your tower of lies has collapsed. TechCrunch is mocking you.';
573
- color = '#ffaa00';
574
- break;
575
- case 'exited':
576
- title = 'VISIONARY FRAUD';
577
- message = `You exited with $${(valuation / 1_000_000).toFixed(1)}M! You are a genius.`;
578
- color = '#00ff7f';
579
- break;
580
- }
581
-
582
- overlay.innerHTML = `
583
- <h1 style="font-size: 48px; color: ${color}; margin-bottom: 10px;">${title}</h1>
584
- <p style="font-size: 18px; color #ccc; max-width: 400px; text-align: center;">${message}</p>
585
- <button onclick="window.location.reload()" style="
586
- margin-top: 30px;
587
- padding: 15px 30px;
588
- font-size: 20px;
589
- background: white;
590
- border: none;
591
- cursor: pointer;
592
- border-radius: 8px;
593
- font-weight: bold;
594
- ">TRY AGAIN</button>
595
- `;
596
-
597
- this.container.appendChild(overlay);
598
- }
599
-
600
- public showLogo(url: string) {
601
- if (!url) return;
602
- const img = document.createElement('img');
603
- img.src = url;
604
- img.className = 'uj-overlay-logo';
605
- this.container.appendChild(img);
606
- }
607
-
608
- public showCrisisAlert(shout: string, desc: string) {
609
- const overlay = document.createElement('div');
610
- overlay.className = 'uj-crisis-overlay active';
611
-
612
- const box = document.createElement('div');
613
- box.className = 'uj-crisis-box';
614
- box.innerHTML = `
615
- <div class="uj-crisis-shout">${shout}</div>
616
- <div class="uj-crisis-desc">${desc}</div>
617
- `;
618
-
619
- overlay.appendChild(box);
620
- this.container.appendChild(overlay);
621
-
622
- // Animate in
623
- setTimeout(() => box.classList.add('visible'), 100);
624
-
625
- // Remove after 4 seconds
626
- setTimeout(() => {
627
- box.classList.remove('visible');
628
- overlay.classList.remove('active');
629
- setTimeout(() => {
630
- overlay.remove();
631
- }, 500);
632
- }, 4000);
633
- }
634
- }
package/tsconfig.json DELETED
@@ -1,21 +0,0 @@
1
- {
2
- "compilerOptions": {
3
- "target": "ESNext",
4
- "useDefineForClassFields": true,
5
- "module": "ESNext",
6
- "lib": ["ESNext", "DOM"],
7
- "moduleResolution": "Node",
8
- "strict": true,
9
- "sourceMap": true,
10
- "resolveJsonModule": true,
11
- "isolatedModules": true,
12
- "esModuleInterop": true,
13
- "noEmit": true,
14
- "noUnusedLocals": true,
15
- "noUnusedParameters": true,
16
- "noImplicitReturns": true,
17
- "skipLibCheck": true,
18
- "declaration": true
19
- },
20
- "include": ["src"]
21
- }
package/vite.config.ts DELETED
@@ -1,20 +0,0 @@
1
- import { defineConfig } from 'vite';
2
- import { resolve } from 'path';
3
-
4
- export default defineConfig({
5
- build: {
6
- lib: {
7
- entry: resolve(__dirname, 'src/index.ts'),
8
- name: 'PreMortem',
9
- fileName: 'pre-mortem',
10
- },
11
- rollupOptions: {
12
- external: ['matter-js'],
13
- output: {
14
- globals: {
15
- 'matter-js': 'Matter',
16
- },
17
- },
18
- },
19
- },
20
- });