« first day (3618 days earlier)      last day (1553 days later) » 
03:00 - 19:0019:00 - 23:00

03:37
Please help me reopen this --->
0
Q: Number of ways of generating Date (data-type) and Promise (data-type) in JavaScript?

DeadpoolIn JavaScript there are various data-types (Object Constructor at core), and various ways to make them. Ways to create Object? Object-Constructor (var obj1 = new Object()) custom-Constructor (var obj2 = new CustomFunction()) Literal (var obj3 = {}) Object.Create (var obj4 = Object.Create(obj1)...

 
4 hours later…
07:40
I copy content from other site and past in frola editor, I am uploading the images my own server using foral API. some images are showing some are not.
But API's all requests have success.
Problem images uploading success on my server and return path but on frola editor do not show image.
Problem images uploading success but sequence of past images are wrong places.
?
08:14
I need an advice. I want to make a game like hearthstone. I have to decide between 2 options: canvas (hard way, perform better) and html elements to be dragged using js. For the second one, I have noticed a bad performance on moving cards with mouse: clickdown a card makes it follow the cursor, clickup, release the card. The card is following the cursor, but with some delay, compared with canvas (I use Phaser3).
same time, I find html approch much much much easy to implement complex effects and animations using css3
would html elements with css3 handle a conplexity like: move 3 complex divs at the same time, add some particles effect
or will 'lag'?
you can move 3 complex divs at once, and most browsers could do so without much difficulty
they'd have to be included in the same div though
I will try to make some basic tests, is worthing because in canvas I have to hardcode even a hover effect
08:41
what is your opinion about learning PHP now for full stack; something like php - symfony 5 - mysql - java script - react; I mean there is also node.js, python, c#
just trying to get some info around the Net; I've seen a ranking where PHP is like #8 in popularity as far as web dev languages (actually #1 result from google.com for something like this)
java script will be a big second half of what I am trying to do, so I will have a better perspective, but I dont have it yet
I mean, I know that PHP is ok, it is not a dead end street
but an option could be to switch to something else maybe and come back to PHP later on, but I am not sure; I will probably continue the PHP
I will be doing the JAVA SCRIPT - REACT part; lets say I have 5 years of experience in both of this currently (I dont); I am wondering what my point of view could be, on this PHP / full stack
this may take me like 3 or 4 years, the php
some people say do it but more superficially and look at other options too (superficially), then decide
https://stackoverflow.com/questions/63843565/ways-of-creating-string-data-type-in-javascript
What's wrong here? Can't someone ask just a basic question - nowadays at Stack_Overflow? Can't someone seriously use this platform for learning? Can't someone expect some "self-proclaimed clever-bees" to NOT interfere, and learn-properly???? What's wrong here in this question ?
I am fed-up what is going on ... in the community nowadays. Just come, downvote, specially -- if you don't have a clue of answer -- for what the question was asked for?
08:55
@AndyRogers PHP is fine, and definitely the easiest to learn. This is the JS room though, and I'm inclined to just tell you to learn node
thanks for the info; node.js / mongoDB later on (as a secondary option); thanks again
I dont have that view of this
and the edu may take me like 3 or 4 more years; I am trying to make sure I am not doing anything wrong
thanks again, I dont want to bother
Mongo is a touchy subject
why, if I can ask?
I was watching a video on Traversy Media channel (YouTube) - web development guide for 2017, 2018, 2019, 2020
he says that MongoDB goes the best with node.js
like there is a thinking - do each more superficially and look at all the options (superficially) - like Python maybe
There have been lots of issues with it in the past regarding atomic operations, stability and security. And they haven't managed to regain trust
I guess I should just stick to PHP and do it properly, in-depth and also the Java Script / React part
looking into Python / Java / C# not really the best idea - do PHP properly, one thing and good
PHP - Symfony 5 - MySQL - Java Script - React --- stick to these, do it good, like 5 years...
no Python, no Java, no C#, no Angular, no Vue, no Node.js
Angulr, Vue maybe once I am somehow done
possibly
but the Python / Java / C# / Node.js route not really; maybe the Node.js after I am done, could be an option, since you have recommended it
so this would be an answer for me
@BenFortune thanks again!
09:05
I wanted to change this code into more statements `for (let number = 12; number <= 24; number ++) {
console.log(number)`
let my_number = 12

for (;;) {
    if (my_number > 24) break;
    console.log(my_number);
    my_number ++;
what does the double ;; stand for ?
yeah don't do that
It's basically a while(true)
09:45
I copy content from other site and past in frola editor, I am uploading the images my own server using foral API. some images are showing some are not.
But API's all requests have success.
Problem images uploading success on my server and return path but on frola editor do not show image.
Problem images uploading success but sequence of past images are wrong places.
?
 
1 hour later…
10:49
Hi all, can you recommend me an IDE that can autocomplete what I type in a separate .js file from all the HTML files in the poject? e.g. getElementById could give me a list of IDs in the HTML files....
@DEKKER 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.
@DEKKER 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.
@JBis the way it works makes me question JS
no errors thrown
the behaviour is weird
@JBis can you make James ignore Wietbot?
turns out James responds to Wietbot because it sometimes starts messages with !!!
like
!!! YAY
'ok'
11:25
@ShrekOverflow yeah its weird, it makes sense, but its weird
not really'
it behaves like a for(I = 0; I< arr.length; I++)
instead of a for of
in C# doing this will run you an error
I wonder if that's spec or implementation.
Eggzactly
This shall be your rise to fame ...
question about for loop does a for loop need 3 statements to "work " ? for example I can write a inifnite loop with this code
for (;;) {
    console.log(my_number);
}
but without the ;; i get an error
yes, js inherited this from c
11:43
good to know
12:16
The reason is mainly useful to skip the initialization of three indexer. That way the indexer can live/continue from an outside scope.
How good/clear that is to do is up for debate though. I highly dislike this. But in c it's often used
12:27
Oi ello
why does eslint throw a warning when return a value of an async function?
async function test () {
	//code

  return user; //Async function 'test' expected no return value.eslintconsistent-return
}

module.exports = {
	test
}
@elsololobo because the async keyword means you're going to return a promise if anything
if you don't return a promise, it isn't an async function anymore
but i declare it as an async function to use await and execute async operations within
can i safely disable this rule?
well the thing getting returned from the await should be user
you won't need to return it
what gets returned from an async function is always a promise
12:43
but this wont work?
async function test () {
	//code

  const user = ['user1', 'user2'];
}

module.exports = {
	test
}


//Execute from
const user = await test.test();
i dont see any issues with that
what error are you getting
//Async function 'test' expected no return value.eslintconsistent-return
from eslint
i was just wondering
because it seems to be just a normal function i wrote 100 times
probably my eslint is already in weekend or I missed something O.o
ah ok
whatever code you have in the funciton is causing issues
@elsololobo A lot of linting applications / websites have been known to have issues with node and especially promises
12:49
Someone needs to make a linter specifically for node, thatd be cool
@JBis the code inside my actual function quite complex and executing several async operations
are you returning anything?
I just implemented to return user, before nothing
can you post the code in a gist?
12:52
I have a jQuery Datatable that is pulling information via AJAX "GET". I want to create a button for my table that allows the user to insert a new list item/table item and use a "POST"?? to send it back to the sharepoint subsite that correlates with that Program
is that possible
@elsololobo yeah so it looks like you are returning nothing at one point and returning user at a different point
@zgoforth everything is possible
but isnt it at the very bottom so that it is return always? Should i declare users empyt at the top to solve this or didnt i got your point?
Didn't mean it like that. I know the POST is, but Im unsure if DataTables has the option to add information to it like that, waiting on a response to my forum post so I figured I would ask here
@JBis ahhh got it. Within one of my IF I returned nothing.... so just changed it to something now its gone
thanks for pointing me in the right direction!
12:57
Oh by the way, I never solved that error that I was dealing with yesterday
I still cant figure out what Im doing wrong..

Uncaught TypeError: Cannot convert undefined or null to object"
Seems to be caused by this code:
Object.keys(defObjects).forEach((e) => {
      console.log(typeof defObjects[e]);
    });
13:11
1
Q: jQuery DataTables New Row Option

zgoforthI have a DataTable that is pulling information from 8 different SharePoint subsites and populate them to one table to view on a landing page. I have done a bunch of research and was unsuccessful in my findings, but is it possible to have a "Add New" button or something along those lines where man...

Going to stop sending questions in here. One of you mfs always immediately goes and downvotes everytime
6
@zgoforth Calling peoples MFS in a chat doesnt help either
and you shouldnt be adverting them here
@zgoforth You can add the row however you like (we usually use modals). Then add it to the data array and use datatables.net/reference/api/draw()
13:27
here we go again
@Cameron thanks
13:38
@zgoforth ok
lol
@Cameron datatables.net/extensions/responsive/examples/display-types/… something along the lines of this?
I guess? Doesn't need to be datatables specific.
well its a Bootstrap version and I am using Bootstrap 4, I was having some issues with certain areas of my code because some of it had to be Bootstrap specific
imo, do "Also, if I wanted to get real serious" part first, then just refresh the table.
ezpz
Werd
13:49
^^ that's how we do it
Follow whatever you find when googling "Bootstrap Modal," that should work fine
reading some interesting things about nosql db's
uhoh
not understanding why they didn't just make a regular sql db write data later
it sounds like nosql was created out of the need for a system that was slowed down because it had to write to disk before returning
why not just remove that condition in an sql db
and also, why remove schema from nosql db's?
@JBis it inherited more than that it seems
How should I frame the question about iterators?
are you posting on main?
13:53
yes
I tried twitter. I only got memes about code-review which is ironic, because nobody is gonna catch this in one
not enough followers for it to become viral
"why is functionality with for loops in js inconsistent with other langauges?"
No
why does js for iterator behaves weird?
naaaaah'
I miss benji
why js be this way
"da faq is dis?"
It's all ogre now
14:16
hows it going ben?
14:33
Sounds like he woke up on the wrong side of the bed
@JBis Going well, no rona yet. How's you?
14:48
Dude...
My teacher gave us an HTML file test
its a small JS program that checks the answers
lol... it just has an array with all the answers
This is just....
absolutely hilarious
@BenFortune That's good. Just started school currently fully remote. Sucks as much as you'd expect.
@JBis dafuk js?
@BenFortune o/ hello!
This chatroom needs a design upgrade
plz no
but having seen recent redesigns from folks, I am terrified to ask
exactly
14:52
@KevinB same feeling
@MisterSirCode Maybe that's the point of the test. To see who is paying attention
I really like when large companies share experiences like this. Very educational. blog.discord.com/…
Slack has gone from, aha nice to oh my lord o lod oh pls make it shttap!
they'll add "New Feature!" tools and then push jobs/teams at us
wait they are redoing chat?
14:53
who knows
doubtful tbh
@JBis thanks
but it'll probably happen one day
forrest and i were working on an extension that transforms SO chat to look like discord
i like rlemon's dark chat, but he's not gonna maintain it. so if they update chat, it's dead
but we got busy
i still cant believe he never came back :(
14:54
Like I could build a better .html file test
in less then 5 minutes
you open the raw HTML and its just the array with the answers in the 5th line
.-.
it's from 2007
give them a break
is that a class on excel?
lol fair enough
yes
whats the class called?
14:56
I didnt exactly CHOOSE it... but Ive somehow managed to get word, powerpoint AND excel honors over 4 times
Excel Honors 10th Grade
Speaking of code from 2007, I feel so bad for all you that had to do web dev back then.
Ah the US
@JBis hey you, it was a fun time nobody cared about ux
i started in 2008, but had t deal with IE7 through 2010
though... i was in college for "web dev" for 06-08
@JBis I feel so bad for all of you that have to do web stuff now
> it was a fun time nobody cared about ux
14:57
Like the html file.... The teacher couldve run the code through obfuscator.io once
lol
@KevinB I started in 2010ish
this chat has my glorious mishaps
@Wietlol web is great now, what are you talking about
like jquery shwarma
or variable phobia
14:57
its just a nightmare to set shit up
i mean
I started webdev back in 2016. Im not nearly as old as yall
jquery was a lifesaver
@ShrekOverflow Well yeah. Who enjoyed putting font tags in every table element? :P
@JBis I assume you know of my views on Javascript
14:58
Jquery WAS probably nice back then, but JS can quickly and efficiently do everything JQuery can do
it can now
lol
now Jquery is just another "Lazy Lib" as I call em
and it just have shortcuts for code
your statement looks quite a bit like how the statement would be after wasm is properly settled
@Machavity I don't enjoy the current react everything
I need a middle ground
@Wietlol bla bla bla
14:59
I am helping folks make a dashboard for a saas project
i don't enjoy the over-complication that seems to happen with most frameworks/libs
you can either use react or go back to 2010
no middle ground :(
like, the way i use typescript vs some other typescript i see are worlds apart
@ShrekOverflow !
Ive never used react, I probably never will, because Im too damn lazy to understand that library.
15:00
Yeah, frameworks disconnect up from what the software is actually doing. I bet most people could not make a DOM element from scratch, bind an event to it and then insert it into the DOM without using some library
react is so damn simple
I really love react... I should try using it at least once :D
never did react-js
@Machavity Dom from scratch and bind an event.... That doesnt sound all that complicated
just use the Custom Elements API, and create a new event
and dispatch it
react is great but its a nightmare to setup. Webpack configs are a nightmare.
it's not, but it seems most new devs now days skipped that step when learning
see people in react not understanding basic javascript concepts
15:01
Kevin thats just how webdevs are these days
"hey guys look at my wix site! Im a master web dev now!!!"
just want to jump in and do the cool stuff first, not understanding what most of it does
Oh well I can relate to that
there are devs today that have never seen .prototype but use class all the time
when I first started learning JS, I completely ignored the basic concepts and just flew right in. Didnt learn anything for weeks.
That was a total failure on my part. I went back to using Functions and basic Object variables
made a small clicker game, and went on from there over the last 2 years
i've never been a fan of building small projects like that
15:04
These days Im developing DX12 Raytracing video games with hand drawn art and such... But as for JS? I can do any basic thing I want.... If I want to make a fancy dynamic webpage using iframe and transition magic? sure thats easy
Besides Node.JS databases and Discord Bots, I really only USE javascript for small projects
I just dont know what else to do with it
i haven't had many projects that were just JS
most of them have been coldfusion, with some JS sprinkled in
Well I want to use JS more often
but like I said
theres not many "big project" or game engines or anything that use Javascript anymore
Unity used to
but that was a hot mess and its been dead for ages
my first big project was a task system with calendar support, support tickets, projects, attachments, approval, projects, teams, and email notifications
massive project, that ended up going really well
what db did you use?
used it in almost every department of the company for a few years
15:06
Sure a big application with web front ends and tons of backend features...

Thats cool, but I dont have any reason to build stuff like that
mssql
what year was that?
MSSQL? What? Ive never heard of this... brb
that was.... 2008-2009
Ohhhh its microsoft sql... I see
15:07
ah very nice
jquery for the frontend i presume
nope
:)
just plain old js
ouch
Good
Im a total jquery hater
and I always will be :D
I havent used Jquery library... since 2018?
pretty cool though
2009-2010 i replaced our entire CMS system's front-end, and used a combination of the history api and jquery to remove page reloads and make the whole thing ajax based... while still supporting IE8
15:08
Just don't be one of those guys that uses jQuery for everything javascript
jQuery can still be useful
i've wanted to work on a project like that
more backend oriented
we're still using that version of the CMS today
if it works it works
though it's certainly got it's problem
@Neil Thats why I hate it though, kids just go on Stackoverflow asking why their "fancy javascript program" doesnt work... and its literally just .val()s and jquery selectors
15:09
coldfusion has been a blessing and a curse
it's so easy to work with, but... nothing supports it
This is how I think of jquery:

code.org blocks > javascript and html
==
jquery > javascript
Its just...
jquery feels childish to me
if it doesn't work, wait until its 5-10 years over due for change and then evaluate the cost to change over to something new, decide it'll be too expensive, and then wait for it to break
in 2008, we were running CF 5, and had to upgrade to 6 due to licensing. that required touching literally every line of code for our intranet system (which is also coldfusion)
then we moved to bluedragon, and now lucee
wait, railo was in there between bluedragon/lucee
what did i say, cf 6 released in 2002, you switched because it broke in 08
15:12
but tldr non-adobe versions of coldfusion
lucee/railo has been great
Im bored... got anything fun I can try making in javascript.

I finished everything for my Excel class... As always, so Im just sitting here optimizing old projects
go build a js app that cures cancer
that should keep you busy for a while
alright, my break is over, cya later o/
let me rephrase:

Got anything fun I can try making that wont take my entire lifespan or more than a year?
I guess Ill make a chrome UI copy in html / css because Im bored as hell and no one has any good ideas for me :O (
15:26
coming up with stuff to do isn't really my thing
i find problems and fix them
¯\_(ツ)_/¯
15:54
@JBis simple?
Compared to pug? here is what you have to do, start the spa, fetch the request, store it somewhere sane (redux?) render this thing? vs just dump HTML vOv
React is an overkill for simple webpages ;), but I've come to live wit hit
we used it once in a SSR setup to build out a mostly static site
so you get the components/jsx rendering
it worked well... but... we ended up just copy pasting all the jsx into coldfusion files and calling it a day
few minor tweaks and it's valid cfml
or cfscript, for the javascript bits
otherwise i've only ever used react for "apps"
like displaying data realtime on a monitor somewhere in the building
hello
whats o/
Ive seen it before
it's a head next to a raised arm, "waving"
16:09
.o/
yeah
I can kinda see it
not really...
: o /
o/
/|
/\
well that didn't work
I give up
Pretty sure thats the chat just deleting extra whitespace
but...
 o/
/|
 /\
that... kinda worked
almost
unicode faces are so awkward
there are times I wish I could type micro spaces
or 1px width spaces
to make those minor adjustments to my emotes
too lazy to copy paste them everywhere
16:26
Holy hot dayum I just discovered SASS.... Im very happy.... this is like the perfect css syntax 0-0
16:42
This is just
beautiful
$mainPageColorStyle : hsl(0, 74%, 63%)
$fontFamily : Verdana

*
	font-family: $fontFamily

.topHeader
	width: 100px
	height: 10px
	background-color: $mainPageColorStyle
 
1 hour later…
17:43
!!🚽
Invalid command! Did you mean: 3, c, ff? Try help for a list of available commands..‍.‍
|| learn 🚽 💩
🚽 has been added
!!🚽
💩
17:58
.-.
18:10
!!🚽
💩
This may be a silly question, but is it possible to run a POST request after a GET request has completed in the same AJAX call?
well, no, as the POST and GEt are two different ajax calls
but i presume what you actually mean is performing a GET request in teh callback.
Ok so I have the GET request that is getting the data from my sharepoint list collection, and I am making a add new row button to my DataTable where you can add new items to the table and it will auto sort it to the correct child row. I then want to send that data to the corresponding SharePoint list
18:15
So to send to the SharePoint list, I would literally do the same thing as I previously did with the GET but just use POST with the same urls?
same urls? dunno. depends on the api you are calling
but a post request isn't much different from a get
base url + _api/web/lists/getbytitle('listName')/items?$select=Program,Deliverable,To,Date,Approved,Notes
  var data = {
            __metadata: { 'type': 'SP.Data.ProjectsListItem' },
           Title: 'Please provide title here',
           Description: 'Please provide multi line text here',
           Start_x0020_Date: new Date().toISOString();
      };
    $.ajax({
        var siteurl = _spPageContextInfo.webAbsoluteUrl;
        $.ajax({
                   url: siteurl + "/_api/web/lists/getbytitle('Projects')/items",
                   method: "POST",
                                 data: JSON.stringify(data),
Found de answer thx tho
18:32
Hello guys. Is there a option how i can track XHR Requests in javascript/selenium? I have searched for a week but nothing work. Iam developing in c# but i can use javascriptexecuter in selenium to execute javascript. Im c# its not possible to track this..
@JamezFatout 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.
18:47
Use developer tools if I think I understand what you are saying. You can filter to only see XHR in the network tab
I used Chrome Dev Tools Libary in C#. But its outdated. The example either dont work.
not exactly understanding what you mean
@zgoforth How i can use the Developer Tools in c#?
18:49
are you working in js or c#? or are you working in c# but runnings tests with js in selenium?
The language shouldnt matter?
Its built into any web browser to be able to track requests once executed
I have tried C# libarys like puppeteersharp and ChromeDevTools but they are not working.
Now i trying to get the xhr request traffic with selenium.
I need it in my C# code to watch the informations and so on..
But i think its not possible in C# so i trie it now with selenium or the selenium javascript execute Functionality.
@ShrekOverflow simple to learn, yes its overkill for simple stuff
03:00 - 19:0019:00 - 23:00

« first day (3618 days earlier)      last day (1553 days later) »