-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathindex.html
More file actions
1170 lines (1135 loc) · 53.3 KB
/
Copy pathindex.html
File metadata and controls
1170 lines (1135 loc) · 53.3 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
705
706
707
708
709
710
711
712
713
714
715
716
717
718
719
720
721
722
723
724
725
726
727
728
729
730
731
732
733
734
735
736
737
738
739
740
741
742
743
744
745
746
747
748
749
750
751
752
753
754
755
756
757
758
759
760
761
762
763
764
765
766
767
768
769
770
771
772
773
774
775
776
777
778
779
780
781
782
783
784
785
786
787
788
789
790
791
792
793
794
795
796
797
798
799
800
801
802
803
804
805
806
807
808
809
810
811
812
813
814
815
816
817
818
819
820
821
822
823
824
825
826
827
828
829
830
831
832
833
834
835
836
837
838
839
840
841
842
843
844
845
846
847
848
849
850
851
852
853
854
855
856
857
858
859
860
861
862
863
864
865
866
867
868
869
870
871
872
873
874
875
876
877
878
879
880
881
882
883
884
885
886
887
888
889
890
891
892
893
894
895
896
897
898
899
900
901
902
903
904
905
906
907
908
909
910
911
912
913
914
915
916
917
918
919
920
921
922
923
924
925
926
927
928
929
930
931
932
933
934
935
936
937
938
939
940
941
942
943
944
945
946
947
948
949
950
951
952
953
954
955
956
957
958
959
960
961
962
963
964
965
966
967
968
969
970
971
972
973
974
975
976
977
978
979
980
981
982
983
984
985
986
987
988
989
990
991
992
993
994
995
996
997
998
999
1000
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>wcstack — What if the browser had these built in?</title>
<meta name="description" content="A thought experiment turned into code. 41 zero-dependency packages: reactive binding, declarative routing, 30+ Web APIs as HTML tags, and in-page devtools — no framework required.">
<meta property="og:title" content="wcstack — What if the browser had these built in?">
<meta property="og:description" content="A thought experiment turned into code. 41 zero-dependency packages: reactive binding, declarative routing, 30+ Web APIs as HTML tags, and in-page devtools — no framework required.">
<meta property="og:type" content="website">
<meta property="og:url" content="https://wcstack.github.io">
<link rel="preconnect" href="https://fonts.googleapis.com">
<link rel="preconnect" href="https://fonts.gstatic.com" crossorigin>
<link href="https://fonts.googleapis.com/css2?family=Space+Grotesk:wght@400;500;600;700&family=JetBrains+Mono:wght@400;500&display=swap" rel="stylesheet">
<style>
/* ── Reset & Base ── */
*, *::before, *::after { margin: 0; padding: 0; box-sizing: border-box; }
:root {
--bg: #060a10;
--bg-card: #0c121a;
--bg-code: #080d14;
--border: #182230;
--border-subtle: #101823;
--text: #d3d9e0;
--text-bright: #f7fafc;
--text-dim: #6f7d8e;
--accent: #38bdf8;
--accent-glow: rgba(56, 189, 248, .12);
--accent-hover: #6dd2fc;
--c-cyan: #38bdf8;
--c-violet: #a78bfa;
--c-green: #5bb98c;
--c-salmon: #d48872;
--c-gold: #d4a017;
--font: 'Space Grotesk', system-ui, -apple-system, sans-serif;
--mono: 'JetBrains Mono', 'Fira Code', monospace;
}
html { scroll-behavior: smooth; }
body {
font-family: var(--font);
background: var(--bg);
color: var(--text);
line-height: 1.7;
-webkit-font-smoothing: antialiased;
}
a { color: var(--accent); text-decoration: none; transition: color .2s; }
a:hover { color: var(--accent-hover); }
code, pre { font-family: var(--mono); }
/* ── Layout ── */
.container { max-width: 960px; margin: 0 auto; padding: 0 24px; }
section { padding: 100px 0; }
/* ── Header ── */
header {
position: fixed; top: 0; left: 0; right: 0; z-index: 100;
background: rgba(6, 10, 16, .9);
backdrop-filter: blur(12px);
border-bottom: 1px solid var(--border-subtle);
}
header .container {
display: flex; align-items: center; justify-content: space-between;
height: 56px;
}
.logo {
font-size: 1.1rem; font-weight: 700; letter-spacing: -.02em;
color: var(--text-dim);
}
.logo span { color: var(--accent); }
nav { display: flex; gap: 22px; }
nav a {
font-size: .8rem; font-weight: 500;
color: var(--text-dim); transition: color .2s;
letter-spacing: .02em;
}
nav a:hover { color: var(--text); }
/* ── Hero ── */
.hero {
padding-top: 180px; padding-bottom: 110px;
text-align: center;
background:
radial-gradient(ellipse 60% 40% at 50% 0%, var(--accent-glow), transparent 70%);
}
.hero h1 {
font-size: clamp(2.2rem, 5.5vw, 3.5rem);
font-weight: 700; letter-spacing: -.03em;
line-height: 1.2;
color: var(--text-bright);
}
.hero h1 em {
font-style: normal;
color: var(--accent);
}
.hero .subtitle {
margin-top: 28px;
font-size: clamp(1rem, 2vw, 1.15rem);
color: var(--text-dim);
max-width: 660px; margin-left: auto; margin-right: auto;
line-height: 1.8;
}
.hero .subtitle-ja {
margin-top: 12px;
font-size: .88rem;
color: var(--text-dim);
opacity: .5;
}
.release-pill {
display: inline-flex; align-items: center; gap: 8px;
padding: 5px 14px; border-radius: 999px;
border: 1px solid var(--border);
background: var(--bg-card);
font-family: var(--mono);
font-size: .74rem; font-weight: 500;
color: var(--text-dim);
margin-bottom: 28px;
transition: border-color .2s, color .2s;
}
.release-pill:hover { border-color: rgba(56,189,248,.35); color: var(--text); }
.release-pill .dot {
width: 6px; height: 6px; border-radius: 50%;
background: var(--c-green);
box-shadow: 0 0 8px rgba(91,185,140,.7);
}
.hero .stats {
display: flex; gap: 0; justify-content: center;
margin-top: 44px; flex-wrap: wrap;
}
.stat {
padding: 0 32px;
border-left: 1px solid var(--border);
}
.stat:first-child { border-left: none; }
.stat .num {
font-size: 1.7rem; font-weight: 700; letter-spacing: -.02em;
color: var(--accent);
line-height: 1.3;
}
.stat .label {
font-size: .72rem; font-weight: 500;
color: var(--text-dim);
letter-spacing: .06em; text-transform: uppercase;
}
.hero .cta-group {
display: flex; gap: 16px; justify-content: center;
margin-top: 44px; flex-wrap: wrap;
}
.btn {
display: inline-flex; align-items: center; gap: 8px;
padding: 10px 24px; border-radius: 6px;
font-size: .88rem; font-weight: 600;
transition: all .2s;
cursor: pointer; border: none;
font-family: var(--font);
}
.btn-primary {
background: var(--accent); color: var(--bg);
}
.btn-primary:hover { background: var(--accent-hover); color: var(--bg); }
.btn-secondary {
background: transparent; color: var(--text-dim);
border: 1px solid var(--border);
}
.btn-secondary:hover { border-color: var(--text-dim); color: var(--text); }
/* ── Section shared ── */
.section-label {
font-size: .7rem; font-weight: 600; text-transform: uppercase;
letter-spacing: .15em; color: var(--accent); margin-bottom: 16px;
}
.section-title {
font-size: clamp(1.5rem, 3.5vw, 2rem);
font-weight: 700; letter-spacing: -.02em;
color: var(--text-bright);
}
.section-sub {
color: var(--text-dim); margin-top: 8px; font-size: .9rem;
}
.section-sub-ja {
color: var(--text-dim); margin-top: 4px; font-size: .82rem;
opacity: .5;
}
/* ── Topics (What's New) ── */
.topics { border-top: 1px solid var(--border-subtle); }
.topics-grid {
display: grid;
grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
gap: 20px; margin-top: 48px;
}
.topic-card {
position: relative;
padding: 28px 24px;
border-radius: 10px;
border: 1px solid var(--border);
background: var(--bg-card);
transition: border-color .3s;
}
.topic-card:hover { border-color: rgba(56, 189, 248, .35); }
.topic-ver {
position: absolute; top: 20px; right: 20px;
font-family: var(--mono);
font-size: .68rem; font-weight: 500;
padding: 2px 8px; border-radius: 999px;
border: 1px solid var(--border);
color: var(--text-dim);
background: var(--bg-code);
}
.topic-card .tag-name { padding-right: 64px; }
/* ── Insight ── */
.insight { border-top: 1px solid var(--border-subtle); }
.insight-body {
margin-top: 32px;
font-size: .95rem;
color: var(--text);
line-height: 1.9;
max-width: 760px;
}
.insight-body strong { color: var(--text-bright); }
.insight-body code {
font-size: .82em;
background: var(--bg-code);
border: 1px solid var(--border-subtle);
border-radius: 4px;
padding: 2px 6px;
color: var(--accent);
}
.insight-ja {
margin-top: 14px;
font-size: .84rem;
color: var(--text-dim);
opacity: .55;
line-height: 1.8;
max-width: 760px;
}
.insight-diagram {
margin-top: 36px;
border: 1px solid var(--border);
border-radius: 10px;
background: var(--bg-code);
padding: 28px 32px;
overflow-x: auto;
}
.insight-diagram pre {
padding: 0; background: none;
font-size: .85rem; line-height: 2.1;
overflow: visible;
}
.insight-diagram .layer { color: var(--text-bright); font-weight: 500; }
.insight-diagram .path { color: var(--accent); }
.insight-diagram .note { color: var(--text-dim); }
/* ── Core packages ── */
.core-section { border-top: 1px solid var(--border-subtle); }
.tag-grid {
display: grid;
grid-template-columns: repeat(auto-fit, minmax(270px, 1fr));
gap: 20px; margin-top: 48px;
}
.tag-card {
padding: 28px 24px;
border-radius: 10px;
border: 1px solid var(--border);
background: var(--bg-card);
transition: border-color .3s;
}
.tag-card:hover {
border-color: rgba(56, 189, 248, .35);
}
.tag-name {
font-family: var(--mono);
font-size: .82rem; font-weight: 500;
color: var(--accent);
margin-bottom: 12px;
display: block;
}
.tag-card h3 {
font-size: 1.05rem; font-weight: 600;
color: var(--text-bright);
margin-bottom: 8px;
}
.tag-card .what-if {
font-size: .85rem;
color: var(--text-dim);
font-style: italic;
margin-bottom: 10px;
}
.tag-card p {
font-size: .85rem; color: var(--text-dim); line-height: 1.6;
}
.tag-card .ja {
font-size: .78rem; color: var(--text-dim); opacity: .5;
margin-top: 6px;
}
.card-link {
display: inline-block;
margin-top: 16px;
font-size: .78rem; font-weight: 600;
letter-spacing: .02em;
}
.tag-features {
list-style: none; margin-top: 14px;
display: flex; flex-wrap: wrap; gap: 6px;
}
.tag-features li {
font-size: .7rem; font-weight: 500;
padding: 3px 8px; border-radius: 4px;
border: 1px solid var(--border);
color: var(--text-dim);
}
/* ── Web API nodes ── */
.io-section { border-top: 1px solid var(--border-subtle); }
.io-grid {
display: grid;
grid-template-columns: repeat(auto-fill, minmax(215px, 1fr));
gap: 10px; margin-top: 44px;
}
.io-node {
padding: 14px 16px;
border-radius: 8px;
border: 1px solid var(--border-subtle);
background: var(--bg-card);
transition: border-color .25s;
}
.io-node:hover { border-color: rgba(56, 189, 248, .35); }
.io-node .io-tag {
font-family: var(--mono);
font-size: .74rem; font-weight: 500;
color: var(--accent);
display: block;
white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}
.io-node .io-desc {
font-size: .72rem; color: var(--text-dim);
margin-top: 3px; line-height: 1.5;
display: block;
}
.protocol-note {
margin-top: 36px;
border: 1px solid var(--border);
border-left: 3px solid var(--accent);
border-radius: 8px;
background: var(--bg-card);
padding: 22px 26px;
}
.protocol-note h3 {
font-size: .92rem; font-weight: 600; color: var(--text-bright);
margin-bottom: 8px;
}
.protocol-note h3 code {
font-size: .85em; color: var(--accent);
background: var(--bg-code); border: 1px solid var(--border-subtle);
border-radius: 4px; padding: 2px 6px;
}
.protocol-note p {
font-size: .84rem; color: var(--text-dim); line-height: 1.7;
}
.protocol-note .ja {
font-size: .78rem; opacity: .5; margin-top: 6px;
}
/* ── Code Examples ── */
.code-section { border-top: 1px solid var(--border-subtle); }
.code-tabs {
display: flex; gap: 0; margin-top: 40px;
border-bottom: 1px solid var(--border);
overflow-x: auto;
}
.code-tab {
padding: 10px 20px; cursor: pointer;
font-size: .8rem; font-weight: 500;
color: var(--text-dim); background: none; border: none;
border-bottom: 2px solid transparent;
transition: all .2s;
font-family: var(--font);
letter-spacing: .02em;
white-space: nowrap;
}
.code-tab:hover { color: var(--text); }
.code-tab.active {
color: var(--accent);
border-bottom-color: var(--accent);
}
.code-panels { position: relative; }
.code-panel {
display: none;
border: 1px solid var(--border);
border-top: none;
border-radius: 0 0 10px 10px;
overflow: hidden;
}
.code-panel.active { display: block; }
.code-header {
display: flex; align-items: center; justify-content: space-between;
padding: 10px 20px;
background: rgba(12, 18, 26, .8);
border-bottom: 1px solid var(--border);
font-size: .75rem; color: var(--text-dim);
}
.code-header .filename { font-family: var(--mono); font-weight: 500; }
pre {
padding: 20px 24px;
background: var(--bg-code);
overflow-x: auto;
font-size: .82rem;
line-height: 1.7;
tab-size: 2;
}
/* Syntax highlight */
code[class*="language-"], pre[class*="language-"] { color: var(--text); text-shadow: none; background: none; }
pre > code[class*="language-"] { padding: 0; }
.token.comment, .token.prolog, .token.doctype, .token.cdata { color: #45566b; font-style: italic; }
.token.punctuation { color: #566b84; }
.token.tag { color: #38bdf8; }
.token.attr-name { color: #a78bfa; }
.token.attr-value { color: #5bb98c; }
.token.string { color: #5bb98c; }
.token.keyword { color: #d48872; }
.token.function { color: #d4a017; }
.token.number, .token.boolean { color: #d48872; }
.token.operator { color: #566b84; }
.token.property { color: #d3d9e0; }
/* ── Rules ── */
.rules { border-top: 1px solid var(--border-subtle); }
.rules-list {
margin-top: 48px;
display: flex; flex-direction: column;
gap: 1px;
background: var(--border-subtle);
border-radius: 10px;
overflow: hidden;
}
.rule {
display: grid;
grid-template-columns: 48px 1fr;
gap: 20px;
padding: 24px 28px;
background: var(--bg-card);
align-items: start;
}
.rule-num {
width: 36px; height: 36px;
display: flex; align-items: center; justify-content: center;
border-radius: 8px;
font-size: .85rem; font-weight: 700;
flex-shrink: 0;
}
.rule h3 {
font-size: 1rem; font-weight: 600;
color: var(--text-bright);
margin-bottom: 4px;
}
.rule p {
font-size: .85rem; color: var(--text-dim); line-height: 1.6;
}
.rule .ja {
font-size: .78rem; color: var(--text-dim); opacity: .5;
margin-top: 2px;
}
.rules-epilogue {
margin-top: 40px;
font-size: .92rem;
color: var(--text-dim);
line-height: 1.8;
max-width: 720px;
}
.rules-epilogue-ja {
margin-top: 12px;
font-size: .82rem;
color: var(--text-dim);
opacity: .5;
line-height: 1.7;
}
/* ── Quick Start ── */
.quickstart { border-top: 1px solid var(--border-subtle); }
.cdn-block {
margin-top: 40px;
border: 1px solid var(--border);
border-radius: 10px;
overflow: hidden;
}
.cdn-note {
margin-top: 16px;
font-size: .85rem;
color: var(--text-dim);
}
.cdn-note-ja {
font-size: .78rem;
color: var(--text-dim);
opacity: .5;
margin-top: 4px;
}
.tooling-note {
margin-top: 32px;
display: flex; gap: 14px; align-items: flex-start;
border: 1px solid var(--border);
border-radius: 8px;
background: var(--bg-card);
padding: 18px 22px;
}
.tooling-note svg { flex-shrink: 0; margin-top: 3px; color: var(--accent); }
.tooling-note p { font-size: .84rem; color: var(--text-dim); line-height: 1.7; }
.tooling-note .ja { font-size: .78rem; opacity: .5; margin-top: 4px; }
/* ── Footer ── */
footer {
border-top: 1px solid var(--border-subtle);
padding: 40px 0;
text-align: center;
}
footer p { font-size: .8rem; color: var(--text-dim); }
.footer-links {
display: flex; gap: 24px; justify-content: center;
margin-bottom: 16px; flex-wrap: wrap;
}
.footer-links a {
font-size: .8rem; font-weight: 500;
color: var(--text-dim);
}
.footer-links a:hover { color: var(--text); }
/* ── Animations ── */
.fade-in {
opacity: 0; transform: translateY(16px);
transition: opacity .6s ease, transform .6s ease;
}
.fade-in.visible {
opacity: 1; transform: translateY(0);
}
/* ── Responsive ── */
@media (max-width: 768px) {
section { padding: 72px 0; }
.hero { padding-top: 140px; padding-bottom: 80px; }
nav { gap: 14px; }
nav a { font-size: .74rem; }
.stat { padding: 0 18px; }
.stat .num { font-size: 1.4rem; }
.rule { grid-template-columns: 40px 1fr; padding: 20px; gap: 14px; }
.code-tab { padding: 8px 12px; font-size: .75rem; }
pre { font-size: .76rem; padding: 16px; }
}
@media (max-width: 560px) {
nav { display: none; }
.hero h1 { font-size: 1.8rem; }
.stats { row-gap: 16px; }
.stat { border-left: none; padding: 0 14px; }
.rule { grid-template-columns: 1fr; }
.rule-num { margin-bottom: 4px; }
}
</style>
</head>
<body>
<!-- Header -->
<header>
<div class="container">
<div class="logo"><<span>wc</span>stack /></div>
<nav>
<a href="#topics">What's New</a>
<a href="#insight">Insight</a>
<a href="#core">Core</a>
<a href="#webapis">Web APIs</a>
<a href="#examples">Examples</a>
<a href="#rules">Rules</a>
<a href="#quickstart">Quick Start</a>
<a href="https://github.com/wcstack/wcstack" target="_blank" rel="noopener">GitHub</a>
</nav>
</div>
</header>
<!-- Hero -->
<section class="hero">
<div class="container">
<a class="release-pill" href="https://github.com/wcstack/wcstack/releases" target="_blank" rel="noopener"><span class="dot"></span>Latest release: v1.21.7</a>
<h1>What if the browser<br>had <em>these</em> built in?</h1>
<p class="subtitle">wcstack is a thought experiment turned into code. We imagine what future web standards <em>could</em> look like — reactive data binding, declarative routing, and thirty-plus Web APIs as plain HTML tags — and build them as if they already existed in the browser.</p>
<p class="subtitle-ja">未来のWeb標準を想像し、それがすでにブラウザに存在するかのようにコードにする思考実験。30以上のWeb APIをHTMLタグに。</p>
<div class="stats">
<div class="stat">
<div class="num">41</div>
<div class="label">Packages</div>
</div>
<div class="stat">
<div class="num">30+</div>
<div class="label">Web API Tags</div>
</div>
<div class="stat">
<div class="num">0</div>
<div class="label">Dependencies</div>
</div>
<div class="stat">
<div class="num">1</div>
<div class="label">Script Tag Each</div>
</div>
</div>
<div class="cta-group">
<a class="btn btn-primary" href="#quickstart">Get Started</a>
<a class="btn btn-secondary" href="https://github.com/wcstack/wcstack" target="_blank" rel="noopener">
<svg width="16" height="16" viewBox="0 0 16 16" fill="currentColor"><path d="M8 0C3.58 0 0 3.58 0 8c0 3.54 2.29 6.53 5.47 7.59.4.07.55-.17.55-.38 0-.19-.01-.82-.01-1.49-2.01.37-2.53-.49-2.69-.94-.09-.23-.48-.94-.82-1.13-.28-.15-.68-.52-.01-.53.63-.01 1.08.58 1.23.82.72 1.21 1.87.87 2.33.66.07-.52.28-.87.51-1.07-1.78-.2-3.64-.89-3.64-3.95 0-.87.31-1.59.82-2.15-.08-.2-.36-1.02.08-2.12 0 0 .67-.21 2.2.82.64-.18 1.32-.27 2-.27.68 0 1.36.09 2 .27 1.53-1.04 2.2-.82 2.2-.82.44 1.1.16 1.92.08 2.12.51.56.82 1.27.82 2.15 0 3.07-1.87 3.75-3.65 3.95.29.25.54.73.54 1.48 0 1.07-.01 1.93-.01 2.2 0 .21.15.46.55.38A8.013 8.013 0 0016 8c0-4.42-3.58-8-8-8z"/></svg>
View on GitHub
</a>
</div>
</div>
</section>
<!-- What's New / Topics -->
<section class="topics" id="topics">
<div class="container">
<p class="section-label">What's New</p>
<h2 class="section-title">Shipped in v1.18 → v1.21.7</h2>
<p class="section-sub">The thought experiment keeps shipping. Four changes worth closing up on.</p>
<p class="section-sub-ja">思考実験は動き続けている。特にクローズアップしたい4つの変更。</p>
<div class="topics-grid fade-in">
<div class="topic-card">
<span class="topic-ver">v1.21</span>
<span class="tag-name"><wcs-devtools></span>
<h3>DevTools, as a tag</h3>
<p class="what-if">What if the inspector shipped as a custom element?</p>
<p>Inspect the live state tree and edit values inline — through the real reactive pipeline, so your edit shows up in the timeline. See exactly which DOM nodes each path is wired to, and watch every write, update batch, and command/event emission scroll by, including zero-subscriber “empty emits.” One script tag, and zero cost when you leave it out.</p>
<p class="ja">ライブな状態ツリーをその場で編集(本物のリアクティブ経路を通る)。各パスがどのDOMノードに繋がっているか、書き込み・バッチ・コマンド/イベント発火のすべてをタイムラインで観察。スクリプト1つ、外せばコストゼロ。</p>
<ul class="tag-features">
<li>State Tree</li>
<li>Binding Map</li>
<li>Live Timeline</li>
<li>Alt+Shift+D</li>
<li>Zero-cost in Prod</li>
</ul>
</div>
<div class="topic-card">
<span class="topic-ver">v1.21</span>
<span class="tag-name"><wcs-raf></span>
<h3>The render loop, declared</h3>
<p class="what-if">What if requestAnimationFrame was a tag?</p>
<p>A vsync-aligned frame loop with a first-class delta. <code>dt</code> is normalized to <code>0</code> across pauses and tab-hidden gaps — an interruption-spanning jump never reaches your physics step, so motion stays frame-rate independent. Hidden tabs stop completely and say so through <code>suspended</code>.</p>
<p class="ja">vsyncに揃ったフレームループと第一級のデルタ。dtは一時停止やタブ非表示をまたぐと0に正規化され、物理ステップにジャンプが漏れない。非表示タブは完全停止し、suspendedで通知。</p>
<ul class="tag-features">
<li>First-class dt</li>
<li>vsync-aligned</li>
<li>tick / elapsed</li>
<li>Tab-aware</li>
</ul>
</div>
<div class="topic-card">
<span class="topic-ver">v1.19</span>
<span class="tag-name">$streams</span>
<h3>Streaming, folded into state</h3>
<p class="what-if">What if an async stream folded straight into a path?</p>
<p>Declare an async iterable, generator, or <code>ReadableStream</code> as a <code>$streams</code> entry, and each chunk folds into one reactive property — with <code>$streamStatus</code> and <code>$streamError</code> companions. Change a dependency and the run aborts and restarts from scratch: switchMap semantics, declared.</p>
<p class="ja">非同期イテラブル・ジェネレータ・ReadableStreamを$streamsに宣言すると、各チャンクが1つのリアクティブなプロパティに畳み込まれる。依存が変われば中断して再スタート — 宣言的なswitchMap。</p>
<ul class="tag-features">
<li>Async Iterables</li>
<li>Fold Pipeline</li>
<li>Dependency Restart</li>
<li>$streamStatus / $streamError</li>
</ul>
</div>
<div class="topic-card">
<span class="topic-ver">v1.21</span>
<span class="tag-name">wc-bindable</span>
<h3>A spec you can machine-check</h3>
<p class="what-if">What if the protocol proved its own conformance?</p>
<p>The <code>wc-bindable</code> manifest — <em>properties</em>, <em>inputs</em>, <em>commands</em> — is now verified by a CI-gated conformance suite across all 41 packages. Add an <code>errorInfo</code> error taxonomy on 27 I/O nodes and an <code>OperationLane</code> guarding every async command, and the thought experiment has the rigor of a real platform.</p>
<p class="ja">wc-bindableマニフェスト(properties / inputs / commands)を、41全パッケージにわたるCIゲート付き適合性スイートが検証。27のI/OノードにerrorInfoエラー分類、各非同期コマンドをOperationLaneが保護。思考実験に本物のプラットフォームの厳密さを。</p>
<ul class="tag-features">
<li>CI Conformance</li>
<li>errorInfo Taxonomy</li>
<li>OperationLane</li>
<li>wcs-validate CLI</li>
</ul>
</div>
</div>
</div>
</section>
<!-- The Core Insight -->
<section class="insight" id="insight">
<div class="container">
<p class="section-label">The Core Insight</p>
<h2 class="section-title">The only contract is a path string</h2>
<p class="section-sub">No hooks. No imports. No glue code.</p>
<p class="section-sub-ja">フックなし。インポートなし。グルーコードなし。</p>
<div class="insight-body fade-in">
<p>In every existing framework, the <strong>component</strong> is where UI meets state. Even with external stores, you still write glue code inside the component to pull state in. State and UI always couple through JavaScript.</p>
<p style="margin-top:14px">wcstack takes a different path. Literally. The <strong>only</strong> contract between UI and state is a <strong>path string</strong> — <code>user.name</code>, <code>cart.items.*.subtotal</code>, <code>@shared</code>. The component's JavaScript doesn't contain a single line that references state. The HTML alone describes every data dependency — the same idea as a REST URL: a simple string contract, no shared code.</p>
</div>
<div class="insight-diagram fade-in">
<pre><span class="layer">State</span> <span class="note">←</span> <span class="path">"user.name"</span> <span class="note">→</span> <span class="layer">UI</span> <span class="note">Path binds the two layers</span>
<span class="layer">Comp A</span> <span class="note">←</span> <span class="path">"@app"</span> <span class="note">→</span> <span class="layer">Comp B</span> <span class="note">Named path crosses components</span>
<span class="layer">Loop</span> <span class="note">←</span> <span class="path">"items.*"</span> <span class="note">→</span> <span class="layer">Template</span> <span class="note">Wildcard abstracts the index</span></pre>
</div>
<p class="insight-ja fade-in">UIと状態を結ぶ唯一の契約はパス文字列。UIを作り直しても状態に触れなくていい。状態をリファクタリングしてもDOMに触れなくていい。HTMLを読めばすべてが分かる。</p>
</div>
</section>
<!-- Core Packages -->
<section class="core-section" id="core">
<div class="container">
<p class="section-label">The Core</p>
<h2 class="section-title">HTML tags that should exist</h2>
<p class="section-sub">What's missing from the browser — and what we built.</p>
<p class="section-sub-ja">ブラウザに足りないもの — そして我々が作ったもの。</p>
<div class="tag-grid fade-in">
<div class="tag-card">
<span class="tag-name"><wcs-state></span>
<h3>Reactive State</h3>
<p class="what-if">What if HTML had built-in reactive data binding?</p>
<p>Reactive state with Mustache syntax, path getters for computed properties, 40+ built-in filters, two-way binding, and structural directives — no virtual DOM.</p>
<p class="ja">Mustache構文、パスゲッター、40以上のビルトインフィルタ、双方向バインディング、構造ディレクティブ対応のリアクティブ状態管理。</p>
<ul class="tag-features">
<li>Mustache Syntax</li>
<li>Path Getters</li>
<li>40+ Filters</li>
<li>Two-way Binding</li>
<li>for / if / else</li>
</ul>
<a class="card-link" href="state/">Learn more →</a>
</div>
<div class="tag-card">
<span class="tag-name"><wcs-router></span>
<h3>Declarative Router</h3>
<p class="what-if">What if you could define SPA routes directly in HTML?</p>
<p>Define routes with nested layouts, typed URL parameters (<code>:id(int)</code>), route guards, and per-route <code><head></code> management. Built on the Navigation API.</p>
<p class="ja">ネストレイアウト、型付きURLパラメータ、ルートガード、ルート別head管理を備えた宣言的ルーティング。</p>
<ul class="tag-features">
<li>Nested Routes</li>
<li>Typed Params</li>
<li>Layouts</li>
<li>Route Guards</li>
<li>Head Management</li>
</ul>
</div>
<div class="tag-card">
<span class="tag-name"><wcs-autoloader></span>
<h3>Component Autoloader</h3>
<p class="what-if">What if the browser could auto-import components just by seeing their tags?</p>
<p>Detects custom elements in the DOM and dynamically imports them via Import Maps. Supports eager & lazy loading with MutationObserver for dynamically added elements.</p>
<p class="ja">DOMのカスタム要素を検出し、Import Mapsで動的インポート。Eager/Lazy読み込みとMutationObserverに対応。</p>
<ul class="tag-features">
<li>Import Maps</li>
<li>Eager / Lazy</li>
<li>MutationObserver</li>
<li>Pluggable Loaders</li>
</ul>
</div>
<div class="tag-card">
<span class="tag-name">@wcstack/signals</span>
<h3>Signals Core</h3>
<p class="what-if">What if TC39 signals were already here — and drove the same tags?</p>
<p>A fine-grained reactive core — <code>signal</code> / <code>computed</code> / <code>effect</code>, async resources, keyed <code>For</code> / <code>Index</code> — the JS-first counterpart to <code><wcs-state></code>, driving the same bindable tags.</p>
<p class="ja">signal / computed / effect、非同期resource、キー付きFor/Indexを備えたシグナルベースのリアクティブコア。stateのJSファースト版。</p>
<ul class="tag-features">
<li>TC39-shaped</li>
<li>Async Resources</li>
<li>Keyed For / Index</li>
<li>bindNode Adapter</li>
</ul>
<a class="card-link" href="signals/">Learn more →</a>
</div>
<div class="tag-card">
<span class="tag-name">@wcstack/server</span>
<h3>Server-Side Rendering</h3>
<p class="what-if">What if your templates rendered on the server — unchanged?</p>
<p>Same HTML, server-rendered. Add <code>enable-ssr</code>, call <code>renderToString()</code>, done. Automatic hydration with zero flicker, and version-safe fallback to CSR.</p>
<p class="ja">同じHTMLをサーバーでレンダリング。enable-ssrを付けてrenderToString()を呼ぶだけ。ゼロフリッカーの自動ハイドレーション付き。</p>
<ul class="tag-features">
<li>Drop-in SSR</li>
<li>Auto Hydration</li>
<li>Zero Flicker</li>
<li>CSR Fallback</li>
</ul>
</div>
<div class="tag-card">
<span class="tag-name"><wcs-fetch></span>
<h3>Fetch as a Tag</h3>
<p class="what-if">What if fetch was a tag?</p>
<p>Declarative HTTP as a headless component. Bind a URL, get data — URL changes automatically re-fetch. htmx-like HTML replace mode, and a headless core that runs in Node.js, Deno, and Workers.</p>
<p class="ja">宣言的HTTP通信。URLをバインドすればデータが届く。URL変更で自動再フェッチ。htmxライクなHTML置換モードも。</p>
<ul class="tag-features">
<li>URL Observation</li>
<li>Trigger Property</li>
<li>HTML Replace</li>
<li>Headless Core</li>
</ul>
</div>
</div>
</div>
</section>
<!-- Web APIs as tags -->
<section class="io-section" id="webapis">
<div class="container">
<p class="section-label">The I/O Nodes</p>
<h2 class="section-title">What if every Web API was a tag?</h2>
<p class="section-sub">Thirty-plus declarative wrappers over the Web platform — each one a headless custom element that binds straight into your state.</p>
<p class="section-sub-ja">Webプラットフォームの30以上のAPIを宣言的タグ化。すべてヘッドレスなカスタム要素として、状態に直接バインドされる。</p>
<div class="io-grid fade-in">
<div class="io-node"><span class="io-tag"><wcs-fetch></span><span class="io-desc">HTTP requests, auto re-fetch</span></div>
<div class="io-node"><span class="io-tag"><wcs-storage></span><span class="io-desc">localStorage / sessionStorage sync</span></div>
<div class="io-node"><span class="io-tag"><wcs-upload></span><span class="io-desc">File upload with progress</span></div>
<div class="io-node"><span class="io-tag"><wcs-ws></span><span class="io-desc">WebSocket real-time comms</span></div>
<div class="io-node"><span class="io-tag"><wcs-sse></span><span class="io-desc">Server-Sent Events streaming</span></div>
<div class="io-node"><span class="io-tag"><wcs-broadcast></span><span class="io-desc">Cross-tab messaging</span></div>
<div class="io-node"><span class="io-tag"><wcs-worker></span><span class="io-desc">Web Worker offloading</span></div>
<div class="io-node"><span class="io-tag"><wcs-timer></span><span class="io-desc">Ticks, elapsed time, polling</span></div>
<div class="io-node"><span class="io-tag"><wcs-raf></span><span class="io-desc">Frame ticks with dt, tab-aware</span></div>
<div class="io-node"><span class="io-tag"><wcs-debounce> <wcs-throttle></span><span class="io-desc">Value & signal coalescing</span></div>
<div class="io-node"><span class="io-tag"><wcs-clipboard></span><span class="io-desc">Clipboard read / write / monitor</span></div>
<div class="io-node"><span class="io-tag"><wcs-geo></span><span class="io-desc">Geolocation, live permission</span></div>
<div class="io-node"><span class="io-tag"><wcs-permission></span><span class="io-desc">Permissions API monitor</span></div>
<div class="io-node"><span class="io-tag"><wcs-notify></span><span class="io-desc">Desktop notifications</span></div>
<div class="io-node"><span class="io-tag"><wcs-intersect></span><span class="io-desc">Visibility, lazy-load, scrollspy</span></div>
<div class="io-node"><span class="io-tag"><wcs-resize></span><span class="io-desc">Element size observation</span></div>
<div class="io-node"><span class="io-tag"><wcs-wakelock></span><span class="io-desc">Screen Wake Lock</span></div>
<div class="io-node"><span class="io-tag"><wcs-camera> <wcs-recorder></span><span class="io-desc">Camera capture & recording</span></div>
<div class="io-node"><span class="io-tag"><wcs-speak> <wcs-listen></span><span class="io-desc">Speech synthesis & recognition</span></div>
<div class="io-node"><span class="io-tag"><wcs-defined></span><span class="io-desc">Custom-element readiness gate</span></div>
<div class="io-node"><span class="io-tag"><wcs-fullscreen></span><span class="io-desc">Fullscreen API</span></div>
<div class="io-node"><span class="io-tag"><wcs-pip></span><span class="io-desc">Picture-in-Picture</span></div>
<div class="io-node"><span class="io-tag"><wcs-pointer-lock></span><span class="io-desc">Pointer Lock for games / canvas</span></div>
<div class="io-node"><span class="io-tag"><wcs-screen-orientation></span><span class="io-desc">Orientation monitor & lock</span></div>
<div class="io-node"><span class="io-tag"><wcs-idle></span><span class="io-desc">Idle Detection</span></div>
<div class="io-node"><span class="io-tag"><wcs-network></span><span class="io-desc">Network Information monitor</span></div>
<div class="io-node"><span class="io-tag"><wcs-share></span><span class="io-desc">Web Share sheet</span></div>
<div class="io-node"><span class="io-tag"><wcs-contacts></span><span class="io-desc">Contact Picker</span></div>
<div class="io-node"><span class="io-tag"><wcs-credential></span><span class="io-desc">Credential Management</span></div>
<div class="io-node"><span class="io-tag"><wcs-eyedropper></span><span class="io-desc">EyeDropper color picker</span></div>
<div class="io-node"><span class="io-tag"><wcs-tilt></span><span class="io-desc">Device Orientation, iOS-safe</span></div>
<div class="io-node"><span class="io-tag"><wcs-accelerometer> <wcs-gyroscope></span><span class="io-desc">Motion sensors (x / y / z)</span></div>
<div class="io-node"><span class="io-tag"><wcs-magnetometer> <wcs-ambient-light-sensor></span><span class="io-desc">Magnetic field & illuminance</span></div>
</div>
<div class="protocol-note fade-in">
<h3>One protocol behind them all: <code>wc-bindable</code></h3>
<p>Every I/O node exposes a static manifest — observable <em>properties</em>, settable <em>inputs</em>, invocable <em>commands</em> — so any binding core can discover and wire it generically. <a href="state/"><code><wcs-state></code></a> and <a href="signals/"><code>@wcstack/signals</code></a> speak it natively; thin adapters connect React, Vue, Svelte, and Solid.</p>
<p class="ja">すべてのI/Oノードは静的マニフェスト(properties / inputs / commands)を公開。stateとsignalsはネイティブ対応、薄いアダプタでReact / Vue / Svelte / Solidからも使える。</p>
</div>
</div>
</section>
<!-- Code Examples -->
<section class="code-section" id="examples">
<div class="container">
<p class="section-label">See it in action</p>
<h2 class="section-title">Code that reads like HTML</h2>
<p class="section-sub">Because it <em>is</em> HTML.</p>
<p class="section-sub-ja">HTMLのように読める。なぜなら、HTMLだから。</p>
<div class="code-tabs" role="tablist">
<button class="code-tab active" data-tab="state" role="tab">State</button>
<button class="code-tab" data-tab="router" role="tab">Router</button>
<button class="code-tab" data-tab="fetch" role="tab">Fetch</button>
<button class="code-tab" data-tab="streams" role="tab">Streams</button>
<button class="code-tab" data-tab="ssr" role="tab">SSR</button>
<button class="code-tab" data-tab="autoloader" role="tab">Autoloader</button>
</div>
<div class="code-panels">
<!-- State -->
<div class="code-panel active" id="panel-state">
<div class="code-header">
<span class="filename">index.html</span>
<span>State</span>
</div>
<pre><code class="language-html"><wcs-state>
<script type="module">
export default {
taxRate: 0.1,
cart: {
items: [
{ name: "Widget", price: 500, quantity: 2 },
{ name: "Gadget", price: 1200, quantity: 1 }
]
},
removeItem(event, index) {
this["cart.items"] = this["cart.items"].toSpliced(index, 1);
},
get "cart.items.*.subtotal"() {
return this["cart.items.*.price"] * this["cart.items.*.quantity"];
},
get "cart.total"() {
return this.$getAll("cart.items.*.subtotal", [])
.reduce((a, b) => a + b, 0);
},
get "cart.grandTotal"() {
return this["cart.total"] * (1 + this.taxRate);
}
};
</script>
</wcs-state>
<template data-wcs="for: cart.items">
<div>
{{ .name }} &times;
<input type="number" data-wcs="value: .quantity">
= <span data-wcs="textContent: .subtotal|locale"></span>
<button data-wcs="onclick: removeItem">Delete</button>
</div>
</template>
<p>Grand Total: <span data-wcs="textContent: cart.grandTotal|locale(ja-JP)"></span></p></code></pre>
</div>
<!-- Router -->
<div class="code-panel" id="panel-router">
<div class="code-header">
<span class="filename">index.html</span>
<span>Router</span>
</div>
<pre><code class="language-html"><wcs-router>
<template>
<wcs-route path="/">
<wcs-layout layout="main-layout">
<nav slot="header">
<wcs-link to="/">Home</wcs-link>
<wcs-link to="/products">Products</wcs-link>
</nav>
<wcs-route index>
<wcs-head><title>Home</title></wcs-head>
<app-home></app-home>
</wcs-route>
<wcs-route path="products">
<wcs-route path=":id(int)">
<product-detail data-bind="props"></product-detail>
</wcs-route>
</wcs-route>
</wcs-layout>
</wcs-route>
<wcs-route fallback>
<error-404></error-404>
</wcs-route>
</template>
</wcs-router>
<wcs-outlet></wcs-outlet></code></pre>
</div>
<!-- Fetch -->
<div class="code-panel" id="panel-fetch">
<div class="code-header">
<span class="filename">index.html</span>
<span>Fetch</span>
</div>
<pre><code class="language-html"><wcs-state>
<script type="module">
export default {
users: [],
loading: false,
filterRole: "",
get usersUrl() {
const role = this.filterRole;
return role ? "/api/users?role=" + role : "/api/users";
},
};
</script>
</wcs-state>
<!-- URL changes automatically trigger re-fetch -->
<wcs-fetch data-wcs="url: usersUrl; value: users; loading: loading"></wcs-fetch>
<template data-wcs="if: loading">
<p>Loading...</p>
</template>
<template data-wcs="for: users">
<div data-wcs="textContent: .name"></div>
</template></code></pre>
</div>
<!-- Streams -->
<div class="code-panel" id="panel-streams">
<div class="code-header">
<span class="filename">index.html</span>
<span>Streams</span>
</div>
<pre><code class="language-html"><wcs-state>
<script type="module">
export default {
prompt: "",
// Fold an async producer into one reactive property.
$streams: {
tokens: {
args: (state) => state.prompt, // dependency captured here
source: (prompt, signal) => llmStream(prompt, signal),
fold: (acc, chunk) => acc + chunk, // accumulate
initial: "",
},
},
};
</script>
</wcs-state>
<!-- Change prompt → the run aborts and restarts (switchMap) -->
<input data-wcs="value: prompt">
<p data-wcs="textContent: tokens"></p>
<p data-wcs="textContent: $streamStatus.tokens"></p>
<p data-wcs="textContent: $streamError.tokens"></p></code></pre>
</div>
<!-- SSR -->
<div class="code-panel" id="panel-ssr">
<div class="code-header">
<span class="filename">server.js</span>
<span>SSR</span>
</div>
<pre><code class="language-javascript">import { renderToString } from "@wcstack/server";