"says"
I had of course already checked and it does not. https://github.com/bitgapp/eqMac/issues/380
So please remind me of why your condescending comment was necessary?
HN user
"says"
I had of course already checked and it does not. https://github.com/bitgapp/eqMac/issues/380
So please remind me of why your condescending comment was necessary?
And which one has a keyboard shortcut for bass/treble smarty pants?
What I really need is a software bass/treble control that can be mapped to keyboard shortcut.
This line of thinking led me to think: global variables should be, rather, considered good!
Plain text is the problem. We write code so it can be easily read as plain text. Not as living, breathing, running code.
Globals are considered bad because they are hard to trace and reason about. But this is only so with plain text. You cannot click on a variable and see all it's dependencies. We must painstakingly trace these.
If we visualized the dependencies and the flow of our code, we could see the complexity as we go. And the "context" becomes automatic. There is no difference between explicit and implicit context.
The key for globals, is to have one large graph data structure where everything is related. All your data is modeled the same. No mini-databases spread out over the code. No ad-hoc indexes strewn throughout. No modularity. One single giant data model.
Yeh horror story was probably too strong a word. I need to try it.
I've heard a lot of horror stories with Swift UI.
I think it's crazy that it's closed source too. It's a big black box which makes debugging hard. Plus its the kind of framework that does a lot of magic stuff where you scratch your head wondering what is going on.
Wow 55K GitHub stars. This is like some record.
Good point. I would prefer to write in HTML/JS. Vanilla JS is probably the way to go.
I think modern frameworks are so bad at perf because they assume people just have so much compute available and are focusing on one app at a time.
When I said "stack/strategy", the _strategy_ part implied this build-for-each-platform approach.
The question still remains then of which to use for each platform.
On macOS there is Cocoa (Swift or ObjC(++) or pure CPP) and Swift UI.
On Windows there is .NET C# or CPP and a bunch of other stuff.
Any thoughts?
Apple should really be investing in their own stuff here.
showed my tax dollars flowing through to that child...would be eye opening
I agree. Charity's often use this for marketing. Making clear the direct human impact of your donation. Tech companies like Apple do this a lot too.
But when a government talks of its successes in statistics...I don't think about my tax spend. I think that it was my (and other people's) vote for that team that did that. And typically not even the team...rather the leadership of the political party.
It's like a shift in the marketing approach.
We sent 100bn to this country to help out with this.
vs.
Average Joe paid 10$ of his income last year which helped pay for this and that for these people. One of those people today was Sally... One of those people 15 years ago was Tracy...
small government
A different spin on "small".
I wonder if you could have micro-governments instead on a per-topic basis with their own mini-budgets.
These omnibus spending bills seem absurd.
The tax should be incurred/realized at the point of the benefit received.
Imagine getting a monthly bill on your estimated tax spend with details of everything it is spent on and how that benefit flows through to you. This might make people more receptive to government.
Also thinking about a Government+ premium subscription service. How can the government offer added benefits to raise more money for things. I guess this is charity.
If companies aren’t forced to NOT pollute, they will pollute
If no one buys their products, or any products with them in the supply chain, then they won't pollute.
Visibility into these supply chains wasn't possible before internet/technology. A free market relies on consumers paying attention which so far they haven't been, because we are too used to relying on the government...and then complain so much about government.
You definitely see consumers driving improvements through their purchasing. Definitely in areas such as sustainability.
I guess regulation addresses a time lag situation. But if a private market developed for a companies that regulates other companies with subscription fees, then this would solve the problem and do it in a better way. Although I'm not sure how the threat of jail can fit into this. Can penalties be strong enough? Is bankruptcy a strong enough disincentive to lie to private regulators.
They are there to stop a single fire from burning down the city.
Interesting point. Definitely has non-excludability.
I remember this scene in Gangs of New York where the firemen fight each other back when it was privatized (don't know if this was real).
rich have freedom of movement but the poor do not
A lot of transport is private. Maybe the poor have more money if they don't have to pay so much in taxes.
Subscription tiers for national defense is funny to think about.
Priority assistance / 24/7 support / merch
Schooling is a tricky one for the free market, and it ultimately gets a bit morally dubious.
I guess you are trying to sell the benefit of a highly-educated country to those who choose private schooling, and getting them to pay for this.
It boils down to how much are you willing to pay for another child's education and what is the acceptable standard of that education.
But if we think about the supply of education, a lot of it is about good teachers, and ultimately someone has to be stuck with the worst teacher in the country. And also class sizes.
I'm interested to dive into this healthcare topic a bit deeper.
To find out what a true free market of healthcare looks like.
Often you find that government intervention distorts markets.
---
...and this looks like the case.
For example, people complain that benefits are tied to employers. But this was caused by the government capping wage increases to combat inflation in 1942, which resulted in companies offering pre-tax health benefits.
This looks like it is changing as people are like: wtf this makes no sense and creates so many bad incentives.
It looks like market forces will fix the system in the end, maybe it just takes 50 years or so.
Maybe I try organizing online, which probably goes nowhere...Very few people have the time, energy, or resources
The thing is...a sector of companies that do this is probably a good business opportunity that is being crowded out by a mandatory government monopoly.
The fact that government does this means that you are already paying for it, and maybe its not being done well.
If people care about their food, they should look for a sticker on their food, from an organization that verifies it. If other people don't have the label, and people know about it, then people won't buy from them.
And if this is too much trouble, then have another industry above this where companies offer all-encompassing ratings on a variety of different things.
With modern technology so much is possible to solve problems that otherwise were too complicated.
You could end up with a marketplace of super apps, that ensure you are completely covered across all avenues of life to the parameters that you desire.
It sounds complicated, but today its even more complicated with government where we rely on the media mostly.
Nobody would pay for the fire department
But they essentially do via their taxes. Implying people understand they need to fund it.
If we imagine a very transparent flow of information regarding fires...people would readily see the need for it. Like how we buy insurance.
All roads could be toll roads. We have technology to track exact usage of roads. Why should cyclists pay for the entire road?
If someone doesn't pay for the roads and gets a delivery, then they delivery company passes on the cost of the road.
If we have very transparent availability of pricing then this becomes possible.
Are companies that don't pay for the EPA allowed to pollute to their heart's content?
If people don't want pollution...they shouldn't buy from companies that pollute.
If people don't want pollution they should ban it from their private property.
With modern tech we can see the entire supply chain of these companies, so consumers can make choices.
inherent monopolies
I've learned to be careful about this "natural monopoly" term because it turns out to be very debatable. Recently with fiber deployments is a good example...see London/UK experience.
I feel like if people realized the benefits to having many companies compete for everything, then they would choose services that did not act like monopolies and to create barriers of entry.
The consumer ultimately dictates how companies should do business. The problem is a lot of the time they are choosing the price that is in front of them, and not considering the price in the future.
If consumers were smarter they could break monopolies without government intervention necessary.
Like if there were two companies building out some critical infra...if one promised they would do it in a way that others could compete easily, and consumers valued that, then they would win the contract.
profit above all else a good objective for government services
This doesn't need to be the case.
People already work for government without profit incentive. It's personal prestige mostly I think.
Interesting to think about what would happen if we introduced duplication and competition within government departments. It seems extremely counter-intuitive because of duplication, but its how the entire capitalist sector deliver efficiencies. Same as how open source works. People compete for prestige.
Corporates sometimes do this too. Google might have multiple teams working on the same goal.
Interesting to think about what would happen if you hired two people to do one job and made them compete against each other on every task.
If you don't have, and don't plan on ever having kids
Then you don't pay for their services, and other people pay more.
Most people don't want an uneducated population so they pay for them.
Government is this strange beast where we continuously seem to vote and pay for all these things we value at the ballot box, but then given the individual choice we change our mind. Or its a matter of "I won't if they don't". Which I guess creates the problem of excludability...if one group is paying for something that those who don't pay for it can't be excluded from...then it's unfair. Then it kind of comes down to everything being modeled as "insurance", such that you are guessing into the future as to what might happen to you and what you might need, and paying based on that.
Maybe its a convenience thing - it takes too much time.
if I don't drive and don't have a car, I'd shortsightedly opt out of paying for road maintenance
I mean if you drive on the road you should pay more. And with modern tech we can now track road usage very precisely.
The *shortsightedly" argument could be resolved with civic education. People need to be more informed about these things. Or its like: if you don't pay for roads, then you get surcharged by any service you use that uses the roads.
which is not to turn a profit
Government is then essentially a bunch of not-for-profits. But instead of multiple tackling the same problem, there is only one.
Nothing implies a need to turn a profit.
Those working in the public sector are incentivized by government committee scrutiny, who are incentivized by winning elections.
So you essentially have a bunch of people who do things for reasons other than money. It's a bit like open source software.
Some people will do things simply because they see there is a better way of doing them, and they enjoy doing it, and perhaps derive secondary benefits like prestige and fame.
By not voting for the "zero tax" party, people continuously show that they derive benefit from the services that their taxes pay for.
Already came across her. She was very good.
I feel like JS needs auto-currying.
function greet(greeting, name) {
return `${greeting} ${name}`
}
const greetWithGreetingHello = greet('hello')
greetWithGreetingHello('sally')
And this should work with named arguments too. function greet({greeting, name}) {
...
}
const greetWithGreetingHello = greet({greeting: 'hello'})
greetWithGreetingHello({name: 'sally'})
With named params, curried functions can be read more naturally too.greetWithGreetingHelloAndWith({name: 'sally'}).
"and with name sally"
"naming fatigue"
ChatGPT is quite good at coming up with names.
It can map a description of a thing to a name. And the descriptions can vary between developers and probably still end up with the same name. So if everyone relies on its naming-prowess then everyone ends up naming things consistently.
Aside: I wonder if it can name parameters from tacit-style...
Write this in non-tacit style:
sort input.txt | uniq -c | sort -rn > output.txt
sort input.txt > sorted.txt
uniq -c sorted.txt > counted.txt
sort -rn counted.txt > output.txt
Seems it can. Look how the output of `uniq` was `counted`.Maybe we should just let ChatGPT name everything.
Interesting to think what programming is you no longer have to name things. A lot of programming is grouping code and coming up with names for the groups.
What if we didn't worry about grouping or naming, and just dealt with the data, and let chatgpt provide names on-the-fly.
Functions could even be replaced by descriptions of the actions.
I wonder if you could let an LLM evolve a graphical operating system from just the hardware definition.
We went through ~70 years of trial and error for programming languages going from low-level to progressively higher-level, and kept all the baggage along the way.
How would an AI go about this...with all the knowledge of today? How would it reason about each step in evolving a language.
I'm guessing it would probably be a LISP :D
Our screens offers only a small window, and even the smartest IDE can’t give us instant access to everything
This is the real problem that needs solving.
code that is read together should be written together
Code is a database of functions. This approach is like trying to design a database in denormalized form.
I've been React for a long time but now I realize its clearly terrible.
I want to go back to the simplicity of Backbone.js where you could easily step through the code.
But at the same time I want to add one big magical abstraction that you can only use with tooling haha.
I want to play with the concepts of:
- one central database of everything: components and data
- visualizing a dependency and data flow graph between everything
Also projectional editor...https://en.wikipedia.org/wiki/Structure_editor
The comment was mainly related to in-memory variables within an application process...focusing on scoping/syntax...but the thinking was definitely inspired by the fact that most apps center around an external database without realizing its essentially a global variable.
In application code, when I talk of global vars, I mean that every function has access to all data...as opposed to access being abstracted and modularized into various services which are exposed via being passed through a chain of function args, or some kind of dependency injection system.
But this global variable could actually be an abstraction (a store) allowing data integrity checks on writes.
there is probably data that we’re working with that is not the state that ultimately persists within the database
If you think about all your data in one big graph, this transient data still has a relation to the final persisted state. There is a data flow of transient values into the persisted data values. And separately, your intermediate data structures might also contain relations to your persisted data structures.
Most dev tools don't track these relationships, and you have this tangled ad-hoc mess where data is dumped from one structure to the next.
“UI state” data...we’d need to include every possible piece of UI state for the whole application in the global store.
Yep, this is what you should do.
If I am sorting something on a webapp and I refresh the browser, I probably want to have see the same things as they were sorted. This might vary between use case, but adding the functionality should be easy to do if necessary. So therefore it is good practice to allow all local ui state to be persisted by default.
The ui state is being persisted anyway, inside a component or inside the HTML document. Somewhere in the heap this data is stored. And if we think about our one big graph again, this data is related to other things...its just that we lose these relations.
A related issue is how to represent temporary clones of significant parts of the data
All rendered UI values should be in their own _ui_ models (view model is similar), separate from the source of truth models.
These ui models basically allow all rendered UI to be editable without immediately committing changes to the database. This allows for optimistic UI updates. They get notified of any incoming changes from the source of truth, and can decide what to do with them.
If you want to batch them up, you just create a Batch entity, and add a relation to these ui models. The main thing is to treat the ui models like any other models. Whether they are persisted or not should simply be flipping a flag in your code.
For UI, everything should be in one big graph. Code is data.
I find with modern programming, all of the popular programming languages, frameworks, libraries, databases, platforms, really get in the way of being able to do things simply.
via what is essentially data tracing
Value tracing is at runtime. JetBrains cannot trace how values flow through your code.
To do this, you need to instrument all your code, and track all the transformations that occur for each value. It's really difficult to do if the language is not designed for it and there are a lot of performance implications.
If your code is written in a functional paradigm it becomes much easier to trace...such as with rxjs.
Yeh, static = lexical.
easier to use
With plain text editors for sure. You really need a mandatory re-imagined IDE to make it work.
You need to be able to see exactly where the variable is coming from...which I think would be a good feature anyway.
And for this you really need a live programming environment...which I think would be good too...but they are very rare. Everyone is obsessed with static typing these days, but runtime value tracing is more useful imho.
Semantic diffs.