正在加载视频...

视频加载失败

i built an entire x86 CPU emulator in CSS (no javascript) you can write programs in C, compile them to x86 machine code with GCC, and run them inside CSS

1,077,051 次观看 • 7 个月前 •via X (Twitter)

53 条评论

Rebane 的头像
Rebane7 个月前

check it out here: :3c

Z 的头像
Z7 个月前

but can it center a div?

Rebane 的头像
Rebane7 个月前

everyone who makes this joke should be forced to read my blog post

Sylvester Hesp 的头像
Sylvester Hesp7 个月前

I don't know how long you've been around, but since you're not addressing it in your blog: there was a time before flex boxes were at thing. Centering a div was exceptionally hard, unless you resorted to using tables. Which everyone did before the semantic web.

Rebane 的头像
Rebane7 个月前

@zelimir__ yes - and i think the history of html/css/browser hacks is really cool! but joking about centering a div these days is just admitting you don't know anything

Sylvester Hesp 的头像
Sylvester Hesp7 个月前

@zelimir__ No, it's just a meme. Like "can it run Crysis".

Rebane 的头像
Rebane7 个月前

@zelimir__ maybe its just because i do so much css stuff, but hearing it over and over again kinda feels like this

Sylvester Hesp 的头像
Sylvester Hesp7 个月前

@zelimir__ Well I can get that someone in your position hears it a lot and can get tired of it 🙂. Back in early 00s I made a raycaster in html4 using vertical <img> slices (canvas didn't exist at the time). Now I wonder if this is doable without javascript 😄

Rebane 的头像
Rebane7 个月前

@zelimir__ that's pretty sick! and i think it is :)

ルナ・サラ (Lunar Schala) 的头像
ルナ・サラ (Lunar Schala)7 个月前

Your bio says "CSS noob", but I think you're at least a CSS sophomore.

Rebane 的头像
Rebane7 个月前

hmm yeah i think i've earned that title by now

Ben 的头像
Ben7 个月前

So at this point, should security-paranoid people who disable Javascript also be switching off CSS?

Rebane 的头像
Rebane7 个月前

@humng392546 depends on your threat model, i use noscript and disable js by default, but don't see css as a threat i need to worry too much about (despite having a css-only chrome cve)

Uncle Ji 的头像
Uncle Ji7 个月前

@humng392546 You reported it. Right?

Rebane 的头像
Rebane7 个月前

@humng392546 yes, that's why i have a cve

Rijnard van Tonder 的头像
Rijnard van Tonder7 个月前

you deserve to know you only need `mov` to be Turing complete. In CSS. Pls report back if you do this

Rebane 的头像
Rebane7 个月前

i am aware of that (and the movfuscator), but like, an entire cpu with the same architecture as your computer is just way cooler

Rijnard van Tonder 的头像
Rijnard van Tonder7 个月前

grant.ed.

Rijnard van Tonder 的头像
Rijnard van Tonder7 个月前

anyway it's just an instruction pass :p css computer will run it

Sylvie 的头像
Sylvie7 个月前

whoa, it's like... assembly... but for the web... imagine if that was an actual thing that would be crazy

ludwig 的头像
ludwig7 个月前

neat

NSG650 的头像
NSG6507 个月前

Oh my god 😭

Yet Another Tech Poster 的头像
Yet Another Tech Poster7 个月前

Truly unhinged code to read from memory I love it @function --readMem(--at <integer>) returns <integer> { result: if( style(--at:-1): var(--__1AX); style(--at:-2): var(--__1CX); style(--at:-3): var(--__1DX); style(--at:-4): var(--__1BX); style(--at:-5): var(--__1SP); style(--at:-6): var(--__1BP); style(--at:-7): var(--__1SI); style(--at:-8): var(--__1DI);

Rebane 的头像
Rebane7 个月前

@function you should post the rests of it

Yet Another Tech Poster 的头像
Yet Another Tech Poster7 个月前

@function Haha i opened the file in vim and i thought it was bugging out

Filip Jerzy Pizło 的头像
Filip Jerzy Pizło7 个月前

That’s fucking awesome

PiX 的头像
PiX7 个月前

you deserve this:

Miguel Piedrafita ✨ 的头像
Miguel Piedrafita ✨7 个月前

you WHAT

CraftyMasterman 🇨🇦 的头像
CraftyMasterman 🇨🇦7 个月前

this is the most redstoner coded coding project of all time

Alula 的头像
Alula7 个月前

jesus fucking christ

William Candillon 的头像
William Candillon7 个月前

can it run Doom?

vik 的头像
vik7 个月前

incredible

♡ mari/cohe ♡ 的头像
♡ mari/cohe ♡7 个月前

fuckin what

Kanbaru 🌟 (one hikari of too many) 的头像
Kanbaru 🌟 (one hikari of too many)7 个月前

fascinated to learn this doesn't rely on JS to advance time, will have to stare at the code later

Asté 的头像
Asté7 个月前

I know you're going to write a blog about this but can you name the most abused trick in this contraption?

Rebane 的头像
Rebane7 个月前

the if() statement combined with a style query combined with collapsing calcs

Josh Hand 的头像
Josh Hand7 个月前

Ok but does it play Doom.

cts🌸 的头像
cts🌸7 个月前

this is awesome!

Kyrylo Silin 的头像
Kyrylo Silin7 个月前

Neat! It makes me wonder is this a new attack vector? It’s kind of like unhinged WASM, but without the guardrails.

Rijnard van Tonder 的头像
Rijnard van Tonder7 个月前

link to implement just `mov` for Turing completeness

webXOS 的头像
webXOS7 个月前

You Gave me some Ideas!

Rebane 的头像
Rebane7 个月前

do these actually work without js? they look very vibe coded

webXOS 的头像
webXOS7 个月前

The pong game probably will never work real time. (due to the logic of the pong ball) but I can get the paddles to move. The emoji quest was based off an already existing JS reliant game ( that i tried to xfer to CSS sort of works but i'm still building.

webXOS 的头像
webXOS7 个月前

Interesting approach though, I have made html/css template document type pages which are nice and clean for the UI. But turning them into full functional PWA is a new realm I am learning.

webXOS 的头像
webXOS7 个月前

Getting some Cool Zine style pages for CSS ideas doing this. Avoiding the JS seems to give the LLM more CSS editing in it's replies (using deepseek browser client for this)

webXOS 的头像
webXOS7 个月前

I am going to try to build a collection of html/css webzine pages with these themes

d-_-b 的头像
d-_-b7 个月前

thats nice

solarite 🍉 的头像
solarite 🍉7 个月前

Bro i swear to god

wtas x 的头像
wtas x7 个月前

Thanks!

ABrownHat 🇻🇦 的头像
ABrownHat 🇻🇦7 个月前

I can't decide whether we should give you a medal or put you in jail.

Diogenes of Cyberborea 的头像
Diogenes of Cyberborea7 个月前

@dante_eats

thomas 🍙 的头像
thomas 🍙7 个月前

Literally how

🌵 Marcel Wiessler 的头像
🌵 Marcel Wiessler7 个月前

Can it run Doom?

相关视频