« first day (3797 days earlier)      last day (1134 days later) » 

12:15 AM
Do most companies who use NodeJS use naked NodeJS and write their own framework? Or do they use Express, or NestJS, or something else?
 
@Birdie 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.
 
 
1 hour later…
1:34 AM
posted on March 09, 2021 by Ben Mason

Hi everyone! We've just released Chrome Beta 89 (89.0.4389.86) for Android: it's now available on Google Play. You can see a partial list of the changes in the Git log. For details on new features, check out the Chromium blog, and for details on web platform updates, check here. If you find a new issue, please let us know by filing a bug. Ben Mason Google Chrome

 
 
1 hour later…
2:50 AM
although my code sucks, its thinking outside of what it can do
new practicalities may come to play
 
3:41 AM
 
4:10 AM
posted on March 09, 2021 by Ben Mason

Hi, everyone! We've just released Chrome 89 (89.0.4389.86) for Android: it'll become available on Google Play over the next few weeks. This release includes stability and performance improvements. You can see a full list of the changes in the Git log. If you find a new issue, please let us know by filing a bug. Ben Mason Google Chrome

 
 
3 hours later…
7:07 AM
All Hi
i have implemented
this is working as expected when i use the accessToken like below
what i want to do is, instead of using accessToken, i want to use the application's clientId and secretId to get the video details
have to find such documentation but have not got any documentation which does the same without accessToken.
is this possible using client and secret?
 
7:34 AM
@Feeds OMG, this XKCD is amazing xD
I mean, basically they all are but I haven't laughed as much for a while.
 
 
1 hour later…
8:46 AM
I have a react project and I'm about to implement some kind of Modal form, anyone care to recommend a lib to use, or is it better to do my own implementation?
I found react-overlays which seems decent enough.
(it's just a modal form (at least for now))
 
 
2 hours later…
10:48 AM
@Markus sweet alert is quite nice - but ofcourse a home built one allows it to be perfect for you
 
For some reason react-overlays dosen't work with my page... not sure why yet... it doesn't close when I click the backdrop...
 
do you have a pen?
 
nope :( it's to complicated and nda'ed
 
11:05 AM
can you show us the code you are using to generate the model then please
specifically where you define the backdrop
 
A minimal example shouldn't contain anything that could realistically be considered to fall under an NDA
 
@Cerbrus thats what i was thinking, but i get that pulling it out into a pen is sometimes a PITA so accept that answer. Hoping that theres something obvious (I have a theory looking at the docs already)
 
11:20 AM
@Markus ask a colleague to assist you
 
11:35 AM
Hi Room,

Is there a way to convert the 'MM/YY' to a date format other than manually split and concatenate after the first slash?
 
11:50 AM
that's probably the way to go. how would any standard util know what day you want for example?
 
any date for example 01. So convert '12/18'(MM/YY) to '12/01/18'(MM/DD/YY)
 
12:12 PM
@Learner Other than using a library? Not really. Do note that if you are working with known formats, string manipulation is actually the best way to go.
Because a single date format is very simple to work with. The trouble is if it's any number higher than one. Especially if you don't know which format you'd get.
||> const str = "12/18"; const [month, year] = str.split("/"); const dateStr = `${month}/01/${year}`; console.log(dateStr);
 
@VLAZ undefined Logged: "12/01/18" Took: 0ms
 
47 messages moved to Trash can
@VLAZ First time right, right? :D
 
I've not used James for a while
Is this new behaviour?
 
Not sure what he was spazzing out about
never seen it before
 
The first time around I used || with code. I wonder if it tried to interpret each word as a command. And maybe succeeded.
I'd rather not try again.
 
12:30 PM
the ||> is used as eval command
 
Yeah, I remembered after James started acting crazy.
 
|| man moist
 
moist: "User-taught command: ` i.ytimg.com/vi/RmCtU6kNnuQ/maxresdefault.jpg`" Creator: Cereal
moist: "User-taught command: ` i.ytimg.com/vi/RmCtU6kNnuQ/maxresdefault.jpg`" Creator: Cereal
 
ok ...
 
Also, you need to escape backquotes in code, if you want template literals.
@KarelG not ok...
 
12:32 PM
@JBis the man command is doing it twice now?
|| unlearn moist
 
||> "hello"
 
@VLAZ "hello" Logged: `` Took: 0ms
You do not have permission to remove this command.
 
Checked if output is also done twice.
 
@VLAZ "hello" Logged: `` Took: 0ms
@VLAZ "hello" Logged: `` Took: 0ms
 
Umm...
 
12:33 PM
You do not have permission to remove this command.
You do not have permission to remove this command.
@VLAZ "hello" Logged: `` Took: 1ms
 
OK, so it's three times with delay?
 
You do not have permission to remove this command.
@VLAZ "hello" Logged: `` Took: 1ms
 
not again...
 
|| sudo disable
 
You do not have permission to remove this command.
@VLAZ "hello" Logged: `` Took: 0ms
@VLAZ "hello" Logged: `` Took: 0ms
 
12:35 PM
K disabled
 
yeah what VLAZ did has caused some issues with the bot
 
Sorry about that
 
it happens :)
 
Ik the problem, I'll fix it in a couple hours
 
Sorry I broke James.
 
12:35 PM
Not your fault, my shitty code
i added something to auto restart the websocket to prevent him from randomly dieing (as he does). I think I forgot to destroy the old websocket. So every message was being registered many times.
 
user14949993
Is it worth shifting my app from vue 2 to vue 3 ?
 
user14949993
I use vuefire for firebase but now vuejs 3 doesn't supports.
 
you got your answer
unless you're willing to invest in that migration
migration is always a matter of weighing potential investment cost towards the return value
 
user14949993
Oh
 
so is it worth to migrate? That is not something we can say. We do not know your codebase.
 
user14949993
12:40 PM
Oh thanks for answering
 
although there are exceptions, such as that the new version introduces a lot (QoL) improvements and/or fixes major problems
for example with Java, it is advisable to migrate to Java 8 or higher if you're still operating from Java 7 or below. 8 has a lot nice features you cannot ignore.
it has low impact. In contrary to migrating to java 9 or higher because of big changes within java API from 8 to 9
know your tech 😁
 
12:58 PM
|| echo "I'm all better now!"
 
I'm all better now!
 
Sorry again guys. Won't happen again (hopefully)
 
||> "hello"
 
@VLAZ "hello" Logged: `` Took: 0ms
 
1:12 PM
l
|| unlearn moist
 
You do not have permission to remove this command.
 
@JBis I am a sad panda now. Can you do that?
 
|| unlearn moist
 
moist has been unlearned
 
(fyi docs says "ALL" for permission)
 
1:13 PM
anyone can call unlearn, but each command has different permissions (depending on creator)
 
> bot owner | command creator
?
 
yes
 
grrr
Firefox really need a solution to end a specific tab like Chrome does
had one hanging, so it froze the whole browser
 
FF is weird like that
 
Doesn't Firefox have indiviudal web content processes?
 
1:20 PM
Sometimes there is a script executing and only some functionality doesn't work.
 
So, an addon could be stuck and you cannot click "Show more comments" on the page (SO, for example).
Killing the subprocess that seems to be stuck might just kill three windows with all their tabs. Or not.
You never really know.
Maybe the entire browser goes because it was some core process you killed.
 
@VLAZ well, that is what it did
it killed the parent process when I killed one of its child
fyi, there is a about:performance if you want to find which tab uses which resources
 
Ooh, I hadn't seen that!
I knew about:memory but hadn't seen this one. Thanks for sharing!
 
1:40 PM
Thanks @vlaz
 
 
1 hour later…
2:48 PM
firefox isnt as wonderful as it once was
 
user14697742
@DrogoNevets and the logo is too oversimplified
 
@LeonhardEuler 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.
 
user14697742
It doesn't look like the good old fox anymore
 
no issues with the logo, makes much more sense than the edge logo
its just slow and clunky these days.
(my opinion)
 
@Jbis
in case you didn't google auth0 lately :D do it :P
 
3:02 PM
why does he have to do that? o.o
 
@ShrekOverflow woah nice
 
Its a good practice to put id as like? $('#item-' + id).find('id').attr();
 
I do not think that you know what .find does
 
o/
I am making a leaderboard that include statistics (such as numbers/hours/minutes/percentages) for different categories. I plan to make it look a lot better than strict HTML, my only experience with dealing with tabular data really I used DataTables with Bootstrap 4. That is what I plan to use but I was curious if anyone in here has ever used any similar plugins ?
 
3:18 PM
Just hakai it
@JBis yeah fun times
what are the new laws around here on self promotion?
 
Get out me swamp
 
in JS chat? i mean, generally it's just don't be annoying,
:p
 
@ShrekOverflow if its relevant and not spammy i don't think anyone will care
 
Has anyone ever used the library Axios?
 
@KarelG I am talking about this $('#item-' + id) I make it dynamic
@BeerusDev yes
 
3:27 PM
An interesting aspect of the calendar protocol (CalDAV) is that you can request anyone's availability. You can't see event details but it does seem a bit intrusive since it's on by default.
 
@Droid how do you like it
 
@BeerusDev fetch call is much faster than ajax call
 
wat
 
@JBis yeah its a bit too much power to be honest
Its as easy as go through 5 different executives cals
if thye all get denied (high chance they are actually in one :P)
but its much better than how facebook would have done it :D (I actually like at-the-very least the response is opaque)
 
4:07 PM
@Droid you can do that, but for maintainability it is a bit tough. I use data- attribute for that. Then I can group those items by class
you can query by data-attribute, which is a simple [data-id="<id>"]
@Droid you need to elaborate on that
 
4:55 PM
@BeerusDev +1 for fetch, and create a API service esque thing (depending on wider framework being used) to handle things (eg auth)
 
@BeerusDev I've never found a need for Axios. I prefer fetch and it's one less dependency.
 
axios is a crutch
people often end up using it(and postman) because they think it fixes their cors issue after a tiny bit of googling
 
ive only ever used it to be lazy, namely when needed to create global interceptors etc quickly for super tight deadlines. as mentioned above that wouldnt be my preferred method, but it does do it mostly nicely
 
I believe axios predates Fetch API
like jquery, it's obsolete now
 
Thanks for the input I just came across it and was curious about it
 
5:03 PM
P.S. where did the idea that typing less is automatically better come from?
 
laziness?
 
why do beginners often try to take shortcuts that decrease readability just because its less characters?
 
Where was typing less mentioned?
 
@JBis just use all the plugins
 
ha, remember that I tried to bring some sanity on those "one liners" group back then
 
5:04 PM
@BeerusDev separate question, someone was here like yesterday with terrible readability in the name of less characters
 
Ah
 
i worked at vodefone uk once, and they got a designer to build the 4G launch page (static page) and on go live day people complained at the speed, so i was asked to look at it and make it more efficient, when asked which plugins he'd used, he literaly replied "all of them" as if that was a serious response
 
It all started when someone wanted to have a "one line solution" for his problem (which is actually an abuse of using () and && )
 
@DrogoNevets what plugins? is this a wordpress site or something?
 
leave these "tricks" to minifiers and write readable code. Seriously. In my first programming lesson, one of the advises was "use the space. A file has numerous white space. Use it"
 
5:07 PM
@JBis i had to work that out. but he meant all the jQuery plugins
 
oh boy
 
i think i counted 53 in the end
for a one page static site
 
53? heh
one of them may be a plugin for doing a leftPad thing, no? 😁
 
i honestly cannot remember now, but it was a mess
i managed to write the whole thing in about 100lines of vanilla JS
 
I loved the anecdote of that Node.js plugin
 
5:09 PM
$.fn.isOdd(5)
 
i do remember more than 1 parralax scrolling plugin (he didnt like the first, so left 1st section using it, and then moved to another for other sections)
 
isOdd should be on $, not $.fn
 
@KarelG i am unaware of this anecdote
 
been a while
 
ok so meta question $.isOdd(5) or 5 % 2 > 0? in any setting
(where 5 is obviously the number to test)
 
5:14 PM
i mean
what would $.isOdd(5) do if not 5 % 2 > 0?
 
function isOdd(num){
   switch (num){
      case 5:
         return true;
      default:
         throw new Error('Unimplemented yet');
   }
}
 
functionally the same, but from a readability perspective etc, which would you prefer to see and why? (imagine you ar eina. code review situ)
@JBis HAHA
 
What should I get for lunch
 
@BeerusDev country?
 
USA
 
5:17 PM
guessing US
 
@DrogoNevets i don't really have anything against an isOdd function. Just write it yourself, don't include a dependency.
 
@BeerusDev no idea, im UK, but we have a chain called CRUSSH which i quite like, got anything similar (healthy, but wholesome food)
@JBis lol i really hope npm has an isOdd and isEven library available to it now :P
 
Wish I had a nandos near
 
it does npmjs.com/package/is-odd 500k downloads this week
 
@JBis this scares me, however also encourages me that my day rate isnt too high
@BeerusDev i though everyone had nandos nearby, i have 2 within 10mins
 
5:22 PM
Yeah but you are in UK?
We do have some but not close at all :(
 
yea UK
@BeerusDev :( got to love a Nandos, though i am upset they stopped doing sunset burger)
 
So good
Haven't had it since I was in London in 2016
 
its all very different atm - i miss eating out
 
FFA
hey, i am having a hard understanding why i cant access my instances inside sagas. any help would be really appriciated :)
stackoverflow.com/questions/66536099/…
 
@FFA 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.
 
5:31 PM
in an api call, the correct syntax for spacing in a url would be %20 correct?
 
@BeerusDev yes
 
452
A: URL encoding the space character: + or %20?

JoeyFrom Wikipedia (emphasis and link added): When data that has been entered into HTML forms is submitted, the form field names and values are encoded and sent to the server in an HTTP request message using method GET or POST, or, historically, via email. The encoding used by default is based on...

 
Say I am calling a list ('Contest Information') --> it would be ('Contest%20Information')
 
err
there's functions for that
 
I saw that article @JBis but I was confused because before in one of my applications I recall using a _x020 or something along those lines
 
yea
that's what i'm referring to
 
The easiest way would be for there to not be any spaces haha which I can control, but Id rather work around so I know how to adapt when I am not in control of what I am "GETTING"
 
@JBis i didnt think generators could be instantiated in anyway and therefore never had access to this?
 
Why bother thining about how a space should be encoded when there's a function that should be used to do it
 
Well I am looking into that now
 
5:35 PM
that's like debating on whether your json string should contain single or double quotes
it's just the wrong question
 
@KevinB sorry yes, replied to wrong person
 
6:34 PM
erg
I've got a metadata field I am trying to GET with my fetch, the field ID is Name. When I specify the field values I want to store in my JSON, I included Name, Field 2, Field 3, Field 4, etc. Every field except for Name worked it tells me
error: {code: "-1, Microsoft.SharePoint.SPException", message: {lang: "en-US",…}}
code: "-1, Microsoft.SharePoint.SPException"
message: {lang: "en-US",…}
lang: "en-US"
value: "The query to field 'Name' is not valid. The $select query string must specify the target fields and the $expand query string must contains Name."
If instead of specifying the items I want to GET and I just do _api/lists/getbytitle('ListName')/items" in my fetch, it pulls the metadata value through, but reads in console as
NameId: 9
NameStringId: "9"
I haven't ever really worked with metadata in this sense, so I am a bit confused. I am trying to research a resolution but haven't had any luck as of yet. Is there a way for the value to return the objects Name value? Or will it always return the ID and String ID?
 
is it just me or is the new facebook extremely sluggish?
thinking react isn't so great
reddit has similar issues
 
You see the new set of Relay Hooks?
 
7:16 PM
posted on March 09, 2021 by Srinivas Sista

The Dev channel has been updated to 90.0.4430.19 for Windows ,Linux and Mac. A partial list of changes is available in the log. Interested in switching release channels? Find out how. If you find a new issue, please let us know by filing a bug. The community help forum is also a great place to reach out for help or learn about common issues. Srinivas Sista Google Chrome 

 
 
1 hour later…
8:19 PM
Ah this metadata issue has been an bug on SharePoint since 2015 and they haven't bothered to fix it.
 
8:48 PM
@JBis In comparison to what specifically? Facebook's front end has been growing exponentially for a while I would assume. Would hate to see the production build size
 
@JesseThompson 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.
 
eh
changing, improving, "growing" in features, doesn't always equate to a larger footprint or slower pages
 
@KevinB yeah I thought about that as I posted that, it seems like such an absurdly complex app though. Hard to get much insight without seeing the code. Maybe Im just a React fanboy
 
@JesseThompson other frameworks?
angular sites seem to be much more responsive
I mean Facebook probably way over complicated their site
 
9:04 PM
Holy sheesh that is so annoying but I finally figured it out

$select=Name/Id,Name/Title&$expand=Name- and thats just for the one field...
 
@JBis I'll probably be more keen to take note what website I'm on next time since you suggest that. I don't doubt you
 
It's not really the best example, but something like apple.com which uses angular is much more responsive to me than facebook.com. And facebook makes react.
However it's very possible facebook is just bad at implementing their own framework
Another example is Google. Google suite uses their own frontend framework and it works much better than react in my experience.
 
 
2 hours later…
11:19 PM
@JBis I don't use facebook nearly enough to experience the difference. I suspect you really have to botch what you're doing or overcomplicate your application to make it slow enough that people can experience the distinction palpably. I've heard that the newer AngularJS has a little better performance though
 

« first day (3797 days earlier)      last day (1134 days later) »