TE
TechEcho
Home24h TopNewestBestAskShowJobs
GitHubTwitter
Home

TechEcho

A tech news platform built with Next.js, providing global tech news and discussions.

GitHubTwitter

Home

HomeNewestBestAskShowJobs

Resources

HackerNews APIOriginal HackerNewsNext.js

© 2025 TechEcho. All rights reserved.

Vim.wasm

576 pointsby fiboabout 6 years ago

51 comments

nyxabout 6 years ago
I thought I was getting stuck in insert mode, and I got fairly frustrated before realizing my Vim keybindings browser extension was grabbing ESC and keeping it from this weird browser-Vim.<p>We brought this abomination on ourselves.
评论 #19746553 未加载
评论 #19744989 未加载
评论 #19746765 未加载
评论 #19749179 未加载
评论 #19744717 未加载
tomjakubowskiabout 6 years ago
Does anyone know if lynx plans on supporting wasm? I&#x27;d like to try this editor in a terminal.
评论 #19746963 未加载
评论 #19745275 未加载
评论 #19744694 未加载
评论 #19746542 未加载
评论 #19747055 未加载
评论 #19755021 未加载
AndyKelleyabout 6 years ago
The GitHub readme has a bunch of great content on it. <a href="https:&#x2F;&#x2F;github.com&#x2F;rhysd&#x2F;vim.wasm" rel="nofollow">https:&#x2F;&#x2F;github.com&#x2F;rhysd&#x2F;vim.wasm</a>
be_erikabout 6 years ago
This is absolutely incredible. I never thought this would be possible-- wasm opens a new phase of software development and deployment.
评论 #19745502 未加载
评论 #19744749 未加载
评论 #19755080 未加载
评论 #19748341 未加载
评论 #19745726 未加载
frutigerabout 6 years ago
<p><pre><code> :colorscheme unknown &quot;that&#x27;s weird :set file^I^I &quot;I guess tab autocomplete doesn&#x27;t work :set filetype=cpp i#include &lt;iostream&gt;&lt;Esc&gt; &quot;I guess syntax highlighting doesn&#x27;t work either :set tabstop=4 softtabstop=4 i^I^I &quot;at least that worked!</code></pre>
kalefranzabout 6 years ago
Where’s the escape key on my iPhone?
评论 #19744238 未加载
评论 #19744479 未加载
评论 #19747312 未加载
评论 #19745259 未加载
评论 #19746366 未加载
评论 #19747637 未加载
monokromeabout 6 years ago
This is pretty dope, but I&#x27;m terrified about the fact that Firefox lets it take over Ctrl+L, Ctrl+1, or any other way (that I can find, at least) of breaking out of Vim with a keyboard aside from closing the tab with Ctrl+W - which is even more terrifying since I use that in Vim a ton, too :O<p>...but this <i>is</i> pretty cool :D
评论 #19746651 未加载
评论 #19746299 未加载
tkinz27about 6 years ago
I wonder if this will be useful for electron based editors like vscode&#x27;s vim plugin. I know the plugin is &quot;good&quot; but I always find something that works in vim and doesn&#x27;t in the plugin and end up going back to my terminal.
评论 #19746498 未加载
webvimbetaabout 6 years ago
The timing on this is really interesting for me. I&#x27;ve been working on a full web vim product (plugins, multi-session, cloud storage, backup, etc.) and I&#x27;m pretty close to a beta product (POC is fully functional, just polishing a few rough edges). If anyone is interested in hearing more, email me at webvimbeta@gmail.com
hq6about 6 years ago
Running on Firefox and `Shift` generates a `^P` character.
评论 #19744712 未加载
评论 #19744351 未加载
评论 #19745959 未加载
评论 #19744465 未加载
jsturgesabout 6 years ago
Not sure if it&#x27;s a bug or user error (not sure if writing is supposed to be supported yet), but after doing the following, the page becomes nonresponsive:<p>:o test.tx :wq I get an fsync failed error and I&#x27;m told to press enter or type a command to continue.<p>I can&#x27;t do either.
positr0nabout 6 years ago
I am impressed that<p><pre><code> :imap jk &lt;Esc&gt; :imap kj &lt;Esc&gt; </code></pre> works great. However it seems like outer and inner text objects aren&#x27;t working at all. E.g. daw, ci)
评论 #19745220 未加载
评论 #19745464 未加载
tinus_hnabout 6 years ago
Perhaps it’s because I block web fonts but once I start typing little turds remain where the intro text was.
评论 #19745881 未加载
评论 #19762857 未加载
评论 #19747612 未加载
mshockwaveabout 6 years ago
:! cat &#x2F;etc&#x2F;passwd<p>[blocked]<p>sorry can&#x27;t help myself trying this. but good job!
评论 #19745572 未加载
khorpyabout 6 years ago
I see many comments on broken key combinations. Obviously, we need to somehow overcome a UI&#x2F;UX limitations of the applications that run inside a browser if we&#x27;re moving into browsers with the consumer apps. I wrote a dedicated article on this: <a href="https:&#x2F;&#x2F;database.blog&#x2F;trello-hot-keys&#x2F;" rel="nofollow">https:&#x2F;&#x2F;database.blog&#x2F;trello-hot-keys&#x2F;</a>
yjhoneyabout 6 years ago
sorry for being dense, but I can&#x27;t seem to save files or do anything seemingly practical. Is there any practical use cases for this library, or is this purely along the lines of &quot;Hey checkout this cool hack!&quot;
评论 #19745303 未加载
评论 #19744630 未加载
评论 #19744500 未加载
评论 #19745305 未加载
zeptomuabout 6 years ago
My test for &quot;non-native&quot; Vim is always &#x27;q:&#x27; which should open a command line window of previous commands at the bottom of your screen - unfortunately that does not work.<p>Furthermore I can&#x27;t use &#x27;Ctrl-v&#x27; that let&#x27;s you select a column of text (EDIT: correction, this <i>does</i> work).<p>&#x27;q:&#x27; should not be captured by the browser? Nevertheless impressive work.
评论 #19747299 未加载
评论 #19747289 未加载
cyansmokerabout 6 years ago
&lt;ctrl-w&gt;w closed my browser window. Should have seen this one coming.
rvalueabout 6 years ago
I was hoping :w with filename would download the contents :D
steve19about 6 years ago
Unfortunately it&#x27;s not working on my android phone with hacker keyboard (full keyboard with esc). There are also horizontal lines across the screen that should not be there.
z92about 6 years ago
Good work. Almost there.<p>Things that doesn&#x27;t work starts from where you might need to change word &quot;ciw&quot;, visually select word &quot;viw&quot;.
idocoabout 6 years ago
My take on vim web version: <a href="http:&#x2F;&#x2F;exitvim2.win" rel="nofollow">http:&#x2F;&#x2F;exitvim2.win</a>
jhareabout 6 years ago
Now I really can&#x27;t quit the internet
bhaakabout 6 years ago
Trying to save errors out with &quot;E667: Fsync failed&quot; and then it gets stuck.
jodrellblankabout 6 years ago
How do Emscripten cross-compiled things and WASM compiled things handle the display? Is it a framebuffer they blindly draw to, do they need shim layers added to interpret normal output to window-scaled in-browser output?
评论 #19746788 未加载
viksitabout 6 years ago
Also see previous discussion about the code on the GitHub repo <a href="https:&#x2F;&#x2F;news.ycombinator.com&#x2F;item?id=17487936" rel="nofollow">https:&#x2F;&#x2F;news.ycombinator.com&#x2F;item?id=17487936</a>
misesabout 6 years ago
Any plug-in support? Could I upload my vimrc to a server, then download it, apply it, and run :PlugInstall to get my vim setup in any web browser?
评论 #19744691 未加载
评论 #19744492 未加载
评论 #19744481 未加载
taf2about 6 years ago
very cool, some of the set commands don&#x27;t seem to work for me... set softtabstop for example didn&#x27;t appear to work. also i might have a local setting but tab complete with set wasn&#x27;t working... again probably local settings. and :w wtf didn&#x27;t work :D seems to crash it. This is super cool<p>[update] ah i see from the readme write support is in the todo list.
foucabout 6 years ago
Why does it completely freeze on :w foo ? It asks for ENTER or any key but that doesn&#x27;t work at all at that point.
curioussavageabout 6 years ago
pretty fun as an experiment. It would be so cool if someday github&#x2F;gitlab had this as an option for editing files
评论 #19745285 未加载
tedmistonabout 6 years ago
On mobile I see a blank gray page. Perhaps this only works on desktop browsers. I still have no idea what it is.
评论 #19747582 未加载
ww520about 6 years ago
Think I crashed it. Did a :w foobar and got an error and the page was stuck, with the computer fan ramped up.
sabujpabout 6 years ago
i had to turn off adblock plus and ublock origin to get this to work for some reason
foucabout 6 years ago
Will wasm ever use html&#x2F;css properly? Or will it just be more like flash?
评论 #19746519 未加载
评论 #19744878 未加载
lone_haxx0rabout 6 years ago
I can&#x27;t save.<p>:w test<p>&quot;test&quot; E667: Fsync failed Warning: original file may be lost or damaged.
yitchelleabout 6 years ago
:q! is not working! Help, I can&#x27;t exit.<p>But seriously, this is great work.
odirootabout 6 years ago
Try inputting some diacritics, it breaks spectacularly.<p>Just tried ą ę ł etc ;)
vldrabout 6 years ago
Next step will be to bundle this in an electron app.
linsomniacabout 6 years ago
Does this get us any closer to being able to edit text fields using vi keybindings? I&#x27;ve tried some of the plugins (long ago) and was underwhelmed with the experience.
评论 #19748087 未加载
SuMu2600about 6 years ago
Is there a good iOS port of Vim available?
评论 #19746544 未加载
mikorymabout 6 years ago
What is the use case for this?
User23about 6 years ago
Vi, the original roguelike.
tomrodabout 6 years ago
This is so cool! Well done!
netmonkabout 6 years ago
How can i save a file ?
评论 #19750546 未加载
diehundeabout 6 years ago
Lol. Why no :Explore?
exabrialabout 6 years ago
Fucking touchbar.
chris_wotabout 6 years ago
Don&#x27;t do :wq
评论 #19744631 未加载
评论 #19744623 未加载
hjk05about 6 years ago
Sounds like a great fun little project. Shame it doesn’t work.
vmarovicabout 6 years ago
diw or ciw doesn&#x27;t seem to work :(
nunobritoabout 6 years ago
Looks good!<p>How can I close it?
sureaboutthisabout 6 years ago
Why was wasm used for this? It&#x27;s not a javascript replacement as stated by webassembly.org.
评论 #19747350 未加载