HN user

thomasfoster96

1,606 karma
Posts88
Comments647
View on HN
www.datcreativity.com 4y ago

The Divergent Association Task

thomasfoster96
1pts0
australiatalks.abc.net.au 5y ago

Australia Talks National Survey 2021

thomasfoster96
2pts0
www.youtube.com 5y ago

“Nothing ever works!” – LinusTechTips and an IoT Garage Door [Video]

thomasfoster96
2pts0
www.youtube.com 5y ago

How Motherboards Work – Turbo Nerd Edition [video]

thomasfoster96
1pts0
twitter.com 5y ago

Facebook has banned Facebook's own Facebook page in Australia

thomasfoster96
19pts4
www.smh.com.au 5y ago

Average lifespan differs by up to 19 years between suburbs in Sydney

thomasfoster96
3pts1
www.crowdatascience.com 5y ago

An intro to useless AFL stats using R

thomasfoster96
2pts0
www.lel.ed.ac.uk 6y ago

Fear and Loathing of the English Passive [pdf]

thomasfoster96
3pts0
www.theguardian.com 7y ago

Australian National University hit by data breach

thomasfoster96
1pts0
cuberule.com 7y ago

The Cube Rule of Food Identification

thomasfoster96
15pts5
www.leafscience.org 7y ago

Investigating Jeanne Calment’s Longevity Record

thomasfoster96
4pts0
motherboard.vice.com 7y ago

Geologists Find Part of the Grand Canyon in Tasmania

thomasfoster96
3pts0
www.bmj.com 7y ago

Renaming low risk conditions labelled as cancer

thomasfoster96
3pts0
insidestory.org.au 7y ago

Like Uber, but for politics: The false promise of digital democracy

thomasfoster96
1pts0
blog.choibean.com 8y ago

Accept my accept-language (2014)

thomasfoster96
1pts0
www.newshub.co.nz 8y ago

Google Translate turns te reo Māori into apocalyptic warning

thomasfoster96
1pts0
www.lel.ed.ac.uk 8y ago

Punctuation and Human Freedom [pdf]

thomasfoster96
2pts0
medium.com 8y ago

The Australian Bureau of Statistics Tracked People by Their Mobile Device Data

thomasfoster96
1pts0
mojonews.com.au 8y ago

Revolutionary system one step closer to saving children’s lives

thomasfoster96
1pts0
mojonews.com.au 8y ago

Learning how to Bitcoin: Australia’s first blockchain uni course launched

thomasfoster96
2pts0
mojonews.com.au 8y ago

Tales from the family vaults: A cult classic

thomasfoster96
1pts0
www.abc.net.au 8y ago

Top secret Australian government documents found in second hand furniture store

thomasfoster96
4pts0
www.youtube.com 8y ago

Stephen Colbert’s Cyborgasm: Home Edition [video]

thomasfoster96
4pts0
www.abc.net.au 8y ago

Quantum Physicist Michelle Yvonne Simmons Named 2018 Australian of the Year

thomasfoster96
2pts0
status.coinbase.com 8y ago

Coinbase down

thomasfoster96
1pts0
www.youtube.com 8y ago

Stephen Colbert’s ‘Go Fund Yourself’ [video]

thomasfoster96
5pts0
www.media.utas.edu.au 8y ago

Living stromatolites found in south-west Tasmania

thomasfoster96
7pts0
en.wikipedia.org 8y ago

2017 Australian parliamentary eligibility crisis

thomasfoster96
1pts0
sports.vice.com 8y ago

Analytics in the AFL – The Most Data Rich Sport on Earth (2016)

thomasfoster96
2pts0
en.wikipedia.org 8y ago

2017 Australian constitutional crisis

thomasfoster96
1pts0

I’ve definitely heard Araucaria araucana called “monkey puzzle” quite often in English, and many people in Australia mistakenly call the bunya pine (Araucaria bidwillii) “monkey puzzle” as well because they are closely related species and look fairly similar (I’m from Australia). There are several species of Araucaria in Australia though, so many people would also be aware of the Norfolk Island pine (Araucaria heterophylla) and probably the hoop pine (Araucaria cunninghamii). I think some people who are familiar with the different species would probably understand that if you said “Araucaria” you would be probably be referring to Araucaria araucana.

Permission.site 5 years ago

This will happen in most browsers (I’m on Safari 14, macOS 11.2). The popup-blockers in most browsers will allow a popup if it is opened directly because of user input, such as a button click — a fairly simple measure which can be implemented by only allowing certain APIs to work within an event handler, for example.

There are a few Web APIs which work this way — for example, you can’t make a page fullscreen unless you do so in response to user input/interaction [0].

[0] https://developer.mozilla.org/en-US/docs/Web/API/Element/req...

You’re right, I was mistaken (and too late to edit my comment).

Out of interest, is there a page anywhere explaining the difference between RustEnhanced and Sublime-LSP + Rust Analyzer? I’ve got both installed, but when I enable Sublime-LSP + RustAnalyzer the experience and functionality is different enough that I assumed it was overriding RustEnhanced.

I would assume that’s entirely possible, but something like this could be done using the HTML5 <video> or <audio> elements for video or audio codecs (there’s even a DOM API to do it! [0]), and some browsers advertised WebP support via the HTTP Accept header [1]. For tracking, I’d assume it’s not very useful these days apart from determining who’s using Safari?

Edit: Not to mention that the onerror event handler on the <img> tag has always been able to find out if an image didn’t display [2].

[0] https://html.spec.whatwg.org/multipage/media.html#dom-naviga...

[1] https://developer.mozilla.org/en-US/docs/Web/HTTP/Content_ne...

[2] https://developer.mozilla.org/en-US/docs/Web/API/HTMLImageEl...

I’d say compared to other languages there’s been two big issues:

1. A not insignificant number of packages are either polyfilling things in browsers, or providing a consistent (or ‘isomorphic') API for certain things across both browsers and Node.js, or adding things that should have been in a standard library.

2. A lot of packages still seem to be distributed primarily as CommonJS and not ES Modules. CommonJS makes tree-shaking harder than it should, so it was often just easier to break what should have been a single library into many smaller pieces.

Hopefully in the not too distant future library maintainers get around to reading the Node.js docs[0] fix some of this.

[0] https://nodejs.org/api/esm.html

This map seems to use a very variable and at times generous definition of both “company” and “still in business”.

Sure, Australia Post is one of Australia’s oldest institutions if you count from the date of the establishment of its oldest predecessor (which this map does, as a Postmaster-General was first appointed for New South Wales in 1809), but a single national postal service wasn’t established until Australia itself was established in 1901 and the colonial postal services were merged, and even then it was a government department until 1975, and wasn’t corporatised until 1989 and remains government-owned to this day.

[...] MyFireWatch shows exactly where those active fires are.

I didn’t link to MyFireWatch precisely because it is showing ‘hotspots’ from the past 72 hours, which is not necessarily the same thing as mapping actual reported fires, hence the confusion of some of the maps talked about in the article. The data on MyFireWatch on areas which have burned is also very inaccurate for some states (Tasmania and Victoria at least).

MyFireWatch explicitly says not to use their map in an emergency[0], because the ‘latest’ hotspot data can be up to four hours old, can be up to 2km out of place (5km in extremes), and may not show fires obscured from or otherwise undetectable from the satellite.

[0] https://myfirewatch.landgate.wa.gov.au/disclaimer.html

As the BBC article suggests, generally the most accurate maps of where recent fires are and how much they’ve burnt are the state government fire or emergency services websites. Unfortunately they are state-by-state (which isn’t usually a problem, but does mean there’s not a good whole-of-Australia map), and some of them show all emergencies, not just fires.

ACT: https://esa.act.gov.au

New South Wales: https://www.rfs.nsw.gov.au/fire-information/fires-near-me

Northern Territory: https://www.pfes.nt.gov.au/incidentmap/

Queensland: https://www.ruralfire.qld.gov.au/map/Pages/default.aspx

South Australia: https://www.cfs.sa.gov.au/site/home.jsp

Tasmania: http://www.fire.tas.gov.au/Show?pageId=colGMapBushfires

Victoria: https://www.emergency.vic.gov.au/respond/

Western Australia: https://www.emergency.wa.gov.au

That’s weird — something else must be influencing the translations.

I’m aware that “condescendiente” doesn’t mean “condescending”, but I’m taking it as evidence that Google Translate interpreted “patronize” with the “to condescend” sense rather than the “to sponsor or support” sense, meaning that word-sense disambiguation works better in those instances.

Yep, I’d put money on Google Translate interpreting the English wrong in the first place. I’ve just tried a bunch of variations on “don’t patronise me.” and these are the results:

"Don't patronise me.” -> "No me patrocines.”

“Don’t patronize me.” -> "No me patrocines.”

"Don't patronise me!” -> "¡No me patrocines!”

“Don’t patronize me!” -> "¡No me patrocines!”

"Do not patronise me.” -> "No me patrocines.”

"Do not patronize me.” -> "No seas condescendiente conmigo.”

“Do not patronise me!” -> "¡No me patrocines!”

"Do not patronize me!” -> "No seas condescendiente conmigo.”

Word-sense disambiguation seems to work if you write “do not” instead of “don’t” and use ‘-ize' spelling, it fails otherwise.

Well, as the linked post says in the first paragraph, almost 90% of the 554 new characters aren’t emoji, and include four new scripts (used by several different languages) and additions for several other scripts. Emoji are only mentioned once in the first half of the article, and unless you consider accessibility-related emoji to be only for a “fringe diversity group”, I’m not sure how the newly added emoji [0] could be particularly controversial?

[0] http://www.unicode.org/emoji/charts/emoji-released.html

I’m not sure about you, but I consider JavaScript running in my browser not being able to write arbitrary text to files to be a good thing.

Otherwise, Node.js can do exactly what you just said Python and MS Basic can do.

This is true of syntax, but it’s not true of the language semantics. There is plenty of perfectly valid JavaScript that isn’t valid TypeScript, so integrating TypeScript into the ECMAScript standard would require something similar to ES5’s “use strict”.

I can’t find the link which details this right now, but I believe there are/were some cases where Flow’s syntax isn’t strictly a superset of JavaScript (to do with generics and comparison operators). I’m not sure whether TypeScript has the same problem or not.

It sounds like I probably haven’t gone deep enough into macro territory then.

Still, when having to do things with JS/Python/C++ I’ve wasted many afternoons down the rabbit hole of trying to glean information from Github Issues, stackoverflow answers, Twitter threads and obscure forum threads — usually to find the problem (and fix) I ran into was so trivial it could have been a single line in an error message. (I feel like a lot of JS tools - particularly Webpack, Jest and Babel - have regressed a fair bit recently in this regard. Python just fails silently (or bizarrely) too often and C/C++ compiler error messages are often less readable than the code itself.)

From personal experience Rust has the lowest “Google search to error message” ratio (if that’s a metric) of any programming tool I’ve used. It’s genuinely a delight to use after having to deal with error messages from various JavaScript tools, Python packages, and C/C++ build tools.

Tok Pisin and other English-based creoles are not simplified English though – they’re languages in their own right where English has served as a major influence. I don’t think that many English speakers would view Tok Pisin inflecting verbs for transivity, having inclusive/exclusive and dual/trial pronouns and making extensive use of reduplication as being simpler.

It is definitely possible but there’s so many more places you could make a mistake if each custom Hook has to do bookkeeping like this. I don't know if I could write or extend the code you wrote without making quite a few mistakes in the process. By comparison, I find following a rule like "calls should be static" much simpler.

The book keeping could be moved into a couple of utility functions - it’d be largely the same for most custom hooks.

I’m also not sure relying on a linter is necessarily going to make static call Hooks simpler. Poorly written hooks are going to be buggy whether they’re Symbol keyed or not. I think that one of the big disadvantages of static call Hooks would seem to be that incorrect conditional usage could still accidentally work.

My post does mention that we care about copy paste experience

I think I misunderstood that section when I first read it - it makes sense now. I’m not convinced it’s a huge win though.

I later go into why allowing conditional declarations of state or effects isn’t even particularly useful or desirable because the semantics are too confusing.

We’ll have to agree to disagree - while I’m not eagerly wanting to use Hooks in conditionals, I dont think the semantics are that confusing.

Here’s what I mean: https://gist.github.com/thomasfoster96/c4a20053c747196f027fc...

A key design goal is that creating a custom Hook is easy. You should be able to literally copy paste part of your component (e.g. a bunch of useState calls and some event handlers) and call it a day.

I'd totally understand that reasoning, because the keyed Hooks are more verbose and would generally require two or three parts of a component to be copy-pasted – but the examples under Flaws #3 and #5 didn't make this clear (to me at least), and I hadn’t seen ‘ease of custom Hook implementation’ cited as an argument against keyed hooks before.

I’m really just playing devil’s advocate here, because in my playing around with Hooks I haven’t yet found a case where keyed Hooks are necessary, but I have accidentally put calls to useState() inside a conditional a heap of times.

Edit: Flaw #5, not #7

How are you going to compose Symbols?

I would’ve used a WeakMap with Symbol keys that mapped to a list or object containing Symbols.

Sorry if I’m just overlooking something obvious, but most of the examples that I’ve seen to explain why Symbol keys aren’t better than the current proposal seem to be just be examples of badly implemented custom hooks, not necessarily flaws with Symbol keys per se.