« first day (3938 days earlier)      last day (993 days later) » 

4:23 AM
Gunna try to blog again (re-blogged from 9 years ago)
https://naftali.lubin.dev/blog/intro-to-recursion
 
Ren
Hello @channel, Is there a recommended Angular component for Accessible (WCAG 2 compliant) Date Time picker?
I could see syncfusion, kendoUI angular library etc..which are all paid ones. Anything else which is free?
 
 
1 hour later…
5:36 AM
@htmlcsscoding The error says what is expected of you. playing should be before src.
 
 
3 hours later…
8:55 AM
@JBis I never said sql is bad, but when using ORM you want to typicaly do things that are not possible in sequel, except with lots of queries. On the other hand things you do with sql are often not used within orms.
@VLAZ Well actually I would think: "why do the orms not use non-agnostic" communication with the database (so they have specific tools for postgres to optimize there etc). And the thing that makes it agnostic is the ORM itself.
This already happens a lot in orms.. Even a simple insertion of a line with with an auto generated ID (using a sequence) needs to be handled differently between sqlite and postgres/mysql. PG/mysql have a "returning" statement that can be added to the query to return the newly generated ID (and other data). Whereas you need with sqlite to actually know the id beforehand, or use last_insert_rowid(), which has all kind of concurrency problems..
 
@paul23 for a dev using an ORM, this is not a problem :)
 
9:11 AM
For unit/integration tests :P
 
^^
somehow YouTube has difficulties to track which part of a long video (> 5 mins) I have been watching
 
though now that we properly moved to knex it actually is a problem, as our tests use sqlite..
So the code is kind of littered with code like:
 
I have seen the video of a given channel completely, let's say it took 21 minutes, but the "track" is staying at 18 minutes. The next time I start to play that channel, it starts from that video I have seen. Hell annoying.
 
export async function dbCreateSheet(user: number, match: number) {
    const db = db('');
    const existing = await db.select('id').from("sheet").where(({user: user, match: match}));
    if (existing.length > 0) {
        throw new OperationalError("Sheet already existing")
    }
    const query = db.insert({
        user: user,
        match: match,
    }).into("scoring_sheet");
    if (db.client.driverName === "sqlite3") {
        await query;
        return (await db.select("id").from("scoring_sheet").where({user: user, match: match}))[0].id;
 
@Cerbrus ! A lot of links??? It's a query on db, if the foreign key to the comment is not null ok, or you don't show it, on the page load. But really, how much years do you program? — Marco Sulla 4 mins ago
Me:
> I like how you question my programming experience, yet you completely ignore the performance implications of what you suggest.
 
9:16 AM
Is that STILL going on? How mad can you be about comments?
 
I mean technically we could think of moving to sqlite completely and hence I prepared the code for that already.. But this is just ugly
 
@VLAZ THE INJUSTICE!
 
No democracy...
 
I did not have gotten any help when I was here on SO ... I had to figure out things at my own
 
Horrors!
 
9:17 AM
@Cerbrus I'm talking about the implementation of the proposal! But are you really a programmer? — Marco Sulla 1 min ago
No, I'm not a programmer. I got 61k rep here simply by being awesome. — Cerbrus 26 secs ago
xD
 
If you don't mind me asking, how old are you @KarelG ? Was that figuring out before SO existed or just cause you didn't use?
 
@Cerbrus the Mgt Burns avatar is a nice fit.
@paul23 30
 
He's probably part of the Iditarod club, but forgot to bring the "tar"
 
Oh that's younger than I am: no excuse to not use so then :P
 
I'll show myself out xD
 
9:20 AM
I started with computer science when I was done with engineering in electromechanics (bachelor). The reason for that was that a professor said I have talent in programming and I should pursue that branch instead of the current I was following
it was a bit weird; I am 2 years older than those people when attending some courses that were for first year
 
Someone please tell me they got the iditarod joke 🙄🥺
 
(started uni at 17)
@Cerbrus sorry, I do not
 
IDItarOD -tar -> idiod
Oh man, I suck, that should've ended with a t...
 
@Cerbrus Ha! You're also an iditrarod :P
 
tbh, I do not understand Marco Sulla's post
 
9:30 AM
Apparently nobody does
Oh, now -he's- asking for peace xD
 
@KarelG The first meta post had people struggling to understand it. Basically all later posts are worse.
 
All of this because of a single deleted comment that orphaned something of his xD
 
anyways, I've placed a comment on his post.
and another one.
 
 
2 hours later…
11:31 AM
@KarelG I restarted a study 6 years in....
 
In the Solution #2: Pub/Sub section, why does it use duplicate() on the publisher? why cant both use same client instance?
Doesn't really explain why
 
@BenBeri the text below it does?
 
What makes it different from a subscriber?
its exactly the same as making two new instances, how are they different
duplicate() makes it a publisher?
Its not explained, from my point of view the client can do both
unless one subscription call changes the state of the client to be a subscriber, and vice-versa
 
duplicate just creates a clone of the said object
the state is being decided by .subscribe and .publish
the duplicate is just a means to create a client quickly. In that code, the publisher instance will be attending on the same url as the subscriber instance
IMHO ... that is not a correct use of code.
duplicate is meant to have multiple subscribers at your disposal, starting from a known client.
re-using a client meant for subscribing as a publisher is ... weird and can lead to problems in the future if someone wants to change the publisher only
 
11:54 AM
I see
thanks
 
Is there a tool that allow for really fast "sketching" of UI design?
 
@paul23 Balsamiq, perhaps
There are also others that allow prototyping a UI.
 
my company uses Invision
has even click features leading to another UI views
It has reduced some workload for the front-end team though. Worth of the money IMHO.
 
12:09 PM
Hmm basically looking for something that allows sketching/updating during presentations
Like "hmm your suggestion would make it look like this.."
"but if we move that button out of that menu, to here we also have to add extra space".
 
For a web application, is it necessary to keep the redis connection alive all the time, or is it better practice to connect every time you need to perform an action and then disconnect ?
 
"And look that would mean that the phone view gets stretched"
 
I think both Balsamiq and I'd assume Invision can do it. Look for UI mockup software. At my current job if we need to do some live mockups, we tend to use Paint and just move stuff around. It's crude but good enough.
Also, we do it rarely.
 
That is the value then that is the error
I stringify the object Error and it says "{}"
 
[object Error] is the default toString() for Error objects.
You should probably try to log err.message
 
12:18 PM
"Cannot read property '\"PTO\"' of undefined"
 
||> let foo = 'fooVal'; 'test ' + `got foo, but without \$, thus being ${foo}?` + ' /test '
 
@KarelG 'test got foo, but without $, thus being foo? /test ' Logged: [ ] Took: 1ms
@KarelG 'test got foo, but without $, thus being fooVal? /test ' Logged: [ ] Took: 0ms
 
k
 
Fixed it
I have got the outsideCount function working perfectly. To overwrite the HTML under my table with the searched content, what do you think the best way of going about that would be. Replace that whole div with a hidden one and when the search function is used, hide the current one and populate the new one? Or individually replace each count
 
1:16 PM
||> let str = ''; str instanceof String
 
@KarelG 'SyntaxError: Unexpected identifier' Logged: [ ] Took: 1ms
@KarelG false Logged: [ ] Took: 0ms
 
annoying quirk
 
1:48 PM
str is a primitive, not an object. Seems fine.
 
yeah, TMK String should be deprecated or at least non-accessible
but nobody made the change. Probably someone has new String in their legacy code? :D
 
Does new String allow some tricks by modifying the string class?
just like new Number
 
ln 632 https://jsfiddle.net/BeerusDev/3yew9kcd/33/

I tried to overwrite the HTML with
$('#under_txtM1').empty();
$('#under_txtM1').html("("+ totalOutsideCount[dayArray.Status]+")");
$('#under_txtM1').val('');
$('#under_txtM1').html("("+ totalOutsideCount[dayArray.Status]+")");
as well as ^, and all it does is add to the count that is already there instead of clearing the span
 
2:14 PM
Hi, does someone know how to force a http request retry within a hook when using the got lib? A retry is not triggered when the http request returns statusCode 404. But under certain conditions I need to force a retry here. Any ideas?
 
@paul23 new String is mostly useless. With ES6 the string class does have some use - you can do class MyString extends String and be safer when adding new custom properties. With that said, I've hardly ever found the need for new methods on native objects. It's much, much easier to create a function that consumes an object, so no change of built-ins needed.
 
 
3 hours later…
5:31 PM
!!mdn shrug
 
An error occurred with the request.
 
5:54 PM
anyone have experience forcing Jest inside a CRA to use ESM modules without ejecting to take over the test script?
 
6:24 PM
o/
 
Hi @BeerusDev
 
6:45 PM
if (moment(dayArray.Date).isBetween(searchMon, searchFri, undefined, '[)')) {
In this I get "Cannot read property 'Date' of undefined". Say Date is xyz, and dayArray is abc... abc.xyz . This means that abc is undefined correct?
 
6:59 PM
it means dayArray is undefined.
i don't get trying to rename it to abc.xyz to say the same thing, lol
 
7:19 PM
Thats what I figured, but I don't get how I am able to console log dayArray in my updateOutsideCount function this is what it logs
 
what's at the very top of that image that is cut off
the first line
 
Hi - I have a question with a 250 bounty on, that I'm struggling with. I've had an answer that outlines the principles and a comment/with a sandbox that is also helpful, but I'm struggling to piece it all together. I'm new to this aspect of JS (it's an image uploader with file delete functionality) I would be unbelievably appreciative if someone could help: stackoverflow.com/questions/68492190/…
 
@TheChewy Welcome to the JavaScript chat! Please review the room rules. If you have a question, just post it, and if anyone's free and interested they'll help. If you want to report an abusive user or a problem in this room, visit our meta.
 
Nothing, it is just a 0:
 
no (i) that when clicked says the result may be dynamic?
 
7:24 PM
Yes there is
 
@TheChewy the image being in your dom, or in cache, is unrelated to it being submitted with your form. When an image is dropped, you added it to your formData. if you want to delete it, you also have to delete it from your formData.
@BeerusDev i suspect the value is undefined when you use it, then becomes defined
 
But now I am realizing that it is not what I think it is getting logged, something else that getting logged which I now commented out.

This is the static version I am using that has the exact same data set/format as my dynamic example:

Static(Working) - https://jsfiddle.net/BeerusDev/3yew9kcd/47/

Dynamic (Throws undefined error at second conditional in updateOutsideCount) - https://jsfiddle.net/BeerusDev/053zyoL4/6/
I have been debugging since lunch. Nothing
I have to use transformedResults.flatMap() in my static version, or else if I use data.Days.flatMap() I get "Cannot read property 'Date' of undefined".

In my dynamic example transformedResults throws "transformedResults is not defined" but then when I use data.Days.flatMap(), I get "Cannot read property 'Date' of undefined"
 
 
1 hour later…
8:59 PM
posted on July 28, 2021 by Harry Souders

Hi, everyone! We've released Chrome Beta 93 (93.0.4577.16) for iOS: it'll become available on App Store in next few days. You can see a partial list of the changes in the Git log. If you find a new issue, please let us know by filing a bug. Harry Souders Google Chrome

 

« first day (3938 days earlier)      last day (993 days later) »