Example of such a report: https://youtu.be/Aa7Q2S7VWUk?si=bqmvmoUBvo0GN1tG
HN user
rolae
People say the title of the article "Ruby Outperforms C: Breaking the Catch-22" is misleading, which is true, this is about Ruby code optimized by JIT outperforming a extension written in C.
But to give some context: the author Aaron Patterson is a Ruby and a Rails core team member. The article and headline is clearly targeting the ruby community, where this article has been very well received. I think it's a good title for the intended audience.
The post clarifies in the first section:
In this post I’d like to present one data point in favor of maintaining a pure Ruby codebase, and then discuss some challenges and downsides of writing native extensions. Finally we’ll look at YJIT optimizations and why they don’t work as well with native code in the mix.
edit: added original title of the hackernews post / article
Not necessarily. Something being too fast can be confusing. If you expect a process to take some time and it ends immediately, it can feel like it failed.
I remember the people from Blogger (google) talking about this problems. People were not very familiar with blog / website builders and users were confused when their blogs got created instantly, like "This is a big deal, me getting an entire website, what happened, what went wrong? It must have aborted the process…"
Both 3.5 and 4 hallucinated according to the professor:
Most used 3.5. A few used 4 and those essays also had false info. I don't think they used any browsing plug-ins but it's possible--it was a take-home assignment and not one they did in class.
Mine was basically ignoring all the mining, get as many food plots as possible, and focus on energy and food. Worked well against the computer, they believed there will be enough supply. But I actually bought out the warehouse and then drove prices extremely high.
So I sold food energy at a higher pricepoint than the ore. Often the AI players couldn't afford food / energy anymore and therefore their production collapsed and they did not have enough food to have enough time to change the installations on their plots.
Bookshop.org is about that, privately funded with the objective to let independent book sellers stand up to the power of amazon.
Andrew Kane created a dataframe gem fairly recently: https://github.com/ankane/rover
Nice. I did something similar recently with an iFrame where you have a form for configuring customer sites and it displays the preview in an iFrame.
I had to throw in some debouncing and special handling for hidden inputs, as changes to hidden inputs do not trigger a change event on the form.
In the end the markup was very simple and is very reusable (StimulusJS v1):
<div data-controller="iframe-preview" data-iframe-preview-url="<%= preview_path(@letter) %>">
<form data-target="iframe-preview.form">
<textarea name="body">My letter</textarea>
</form>
<iframe data-target="iframe-preview.iframe">
</div>
This is when StimulusJS becomes really nice, when you can compose behavior in your markup with some simple data attributes. I did not think at first that I would need this controller in other places, but a couple of weeks later, I actually needed it, and was able to reuse the controller without modification for another use case.That was a regression in version 3.4, fixed here: https://github.com/hopsoft/stimulus_reflex/pull/418
Exactly.
Basically all you to is to call a remote procedure, which you can do by adding a simple `data-reflex="click->Todo#toggle`. In the remote method you change something about the state (for example db, redis). The server rerenders the page and morphs the difference.
If you need more control you can get it by defining which elements to render and to morph.
It looks beautiful, but please increase the contrast. Some texts are #aaa on #fff, which is almost illegible. This is an accessibility issue not just for people with impaired vision, also for people checking a page on a mobile phone on a sunny day.
Just as you did here most people who submit a Show HN give a short description of what they did in a comment. I think it would be a good addition to include the posters top level comments in the detailed view.
For people on Rails I recommend checking out https://www.heya.email/ from The guys at honeybadger. It is a paid/open source gem, that will let work with the db data instead of having to transmit all that user data to a third party.
Rails has very much embraced webpack and different ways to build SPA on it, with providing an API only mode and easy install webpacker install commands. Maybe for an oppinionated framework it now offers too many ways to do the frontend.
But more importantly, Rails is still insanely productive to work with. And with gems like stimulus_reflex and matestack you can get reactivity easily without having the complexity of full blown SPAs.
No, there are three layers on how to use matestack. Without reactivity, it just creates pure HTML. If you use reactive functions like :onclick, :toggle, :async, you basically configure/fill VueJS components provided by matestack. On the third layer you can write your own VueJS components in Javascript, but still use the matestack DSL to then use/configure it.
Stimulus Reflex https://docs.stimulusreflex.com/
Laravel Livewire https://laravel-livewire.com/
Phoenix LiveView https://github.com/phoenixframework/phoenix_live_view
That's where I see a lot of potential. With Stimulus Reflex I have the convenience and development speed of Rails and I can enhance it with StimulusJS sprinkles and reflexes to create great experiences for the user. The interactivity I get is enough for 90%+ of the webapps out there and the complexity to do it is far less.
Meteor.js maybe, not sure of its focus nowaday, back when I played around with it, you had basically a MongoDB that you could query and mutate on the client, everything was then synced via a pub/sub system with the server.
Reminds of an episode of the programm (audio series). [1] They used GTP-3 to generate most of the answers the AI gives in that episode.
It is generally a fascinating series, set in a fictional future, where the program took control of the world. But it is less about that future, but more of a look back on today's world from fictional future.
[1] https://programaudioseries.com/14-more-parrot-than-predator/
With Stimulus Reflex we are getting pretty close.
To document with videos is valuable, but I think the site should provide as much context as possible, what I would wish for, show:
* Date of incident
* Short description of context
* Primary source, or at least, where the video was found
* Media coverage of incident
* Updates on convictions/official investigations into the incident
* Official statements / responses
* linked videos (videos of the same incident, but with other view-angle)
Otherwise it will just be a collection of outrage, if you don't give real data to put things into context.edit: formatting
To document single incidents of brutality has value. The documentation of one single act of police brutality has value. As the police has a monopoly on the legal use of violence they have to be held accountable.
This is like saying building a registry/counting murders has no value and brings no insight.
And this has nothing todo with condoning violence of protesters, which is just as wrong as police brutality. The issue is, that police never seems to be held accountable for excessive use of force.
Refactoring Ruby
I am a UX person, but often dabbled in Ruby on Rails. Currently for the the first time working on a more serious app and now reading the book refactoring ruby, is very illuminating, going through my code again and rereading makes me see many mistakes and possible improvements.
There are hundreds of wireframing / prototoyping tools out there, I tried many of them, I would still recommend Balsamiq for non-designers. It stays true to its core, to keep things simple and fast. Sketch & Figma will slow you down, so unless you need to create highly interactive prototypes or you want to do visual design, then I say, stick to it.
I recently gravitated back towards Balsamiq, as I helps me think at the right level, and not go too much into detail.
And love their licensing, I bought a license 10 years ago, and got ten years of upgrades. Recently they had their first paid upgrade in ten years, this is just unmatched in commercial software.
Intercooler is all about getting HTML into your DOM that you get from AJAX requests without actually writing any Javascript. Alpine is more about Interactivity within the current page, without doing a request first. It keeps the state in a data object.
Of course you can do similar things as you would do in Intercooler, but it would be explicit in the Javascript part. See this example they give for prefetching dropdown content from the server
<div x-data="{ open: false }">
<button
@mouseenter.once="
fetch('/dropdown-partial.html')
.then(response => response.text())
.then(html => { $refs.dropdown.innerHTML = html })
"
@click="open = true"
>Show Dropdown</button>
<div x-ref="dropdown" x-show="open" @click.away="open = false">
Loading Spinner...
</div>
</div>Alpine.js really was created for javascript sprinkles, where even vue.js might be overkill. For example, if you have an app, but you need to have dropdowns and modals. Then something like alpine.js can be nice.
So it is actually not intended for things more complex than basic interactivity. And what you build with it, should be simple enough you don't need any type system.
For people interested, there is a good episode on FullStackRadio on the topic http://www.fullstackradio.com/132
While the spirit of using a simple library for javascript sprinkles to enahnce your app is similar, stimulus.js and alpine.js are quite different:
Alpine.js has the x-data property, to keep state that you can manipulate, in stimulus all state is directly in the DOM. So for example to make a modal with stimulus, you would add a class to show a hidden overlay. In Alpine you would use a x-show property, that reacts to a change in the data of the component.
So the big difference is that alpine has a reactive data context as a first class citizen. In a way it is actually much more similar to AngularJS 1.x than to stimulus, with the idea that it is really intended only to be used to enhance existing html, not to build whole apps with it.
If you want some good visual design tips, then I can recommend https://refactoringui.com/
I can also highly recommend the book they sell.
Reminds of when I was not able to log into Skype, because when I typed in my username, which was something like firstname...familyname, it kept replacing the three dots with an elipsis automatically, without me noticing.
While true, the number of 90% is a little misleading. The vote was declared unconstitutional and illegal by Spanish government, so many people against a separation did not show up to vote. However with a voter turnout of 43%, it is still a strong signal in favor of separation.
https://en.wikipedia.org/wiki/2017_Catalan_independence_refe...
Have a look at descript, an podcasting app. They do this, but not just for playback. They actually let you edit the audio by editing the text transcript.