« first day (2230 days earlier)      last day (2943 days later) » 

Knu
Knu
00:00
I am screwed :)
No, response headers are different from request headers
They have different names and different meanings
Knu
Knu
@copy OK then let's ask this differently what are the request headers that have a 1 to 1 relationship to their response header counterpart?
I don't know
There are many headers, you know
Knu
Knu
Would Content-Type be one of them?
I just need one.
nvm found a ressource :)
00:30
oooooooooooh my god
@KendallFrey Well I know who Im hiring for my next website!
user6820627
can you explain this to me? i can't understand those strange numbers!
user6820627
in 2016 Stack Overflow Moderator Election, 5 hours ago, by SmokeDetector
OpenSTV version 1.7 (http://www.OpenSTV.org/)

Suggested donation for using OpenSTV for an election is $50.  Please go to
http://www.OpenSTV.org/donate to donate via PayPal, Google Checkout, or
Amazon Payments.

Certified election reports are also available.  Please go to
http://www.openstv.org/certified-reports for more information.

Loading ballots from file votes.blt.
Ballot file contains 10 candidates and 30277 ballots.
No candidates have withdrawn.
Ballot file contains 30277 non-empty ballots.
user6820627
^ (no, read the full message, this is not.)
00:44
@KendallFrey lmfao
@Loktar checked around. reviews for that setup breakdown prices and I'm paying $50 more to get it pre assembled and delivered to me
@KendallFrey LOL
so, I'm okay with that
@KendallFrey where did you get it?
user6820627
@littlepootis again :(
Oh, kendall posted this already'
!!play league of legends or write code
@Abhishrek play league of legends
:D
!!play hitman or play league
01:16
@Abhishrek play league
god damnit
01:29
This is still just about the greatest thing to ever come out of unsolicited spam we get over at @StackOverflow. https://twitter.com/JasonPunyon/status/542003498611511296
2
hehe, phone number
 
1 hour later…
02:41
Hello everyone!
@TriHard8 Welcome to the JavaScript chat! Please review the room rules. Please don't ask if you can ask or if anyone's around; just ask your question, and if anyone's free and interested they'll help.
I'm writing a script to download some data from a website where I have to login...What are some key words/phrases that I can google to help with this? I know the main SO pages have a couple things, but they really don't explain what's going on.
I should add, that i'm just looking for assistance with the logging in aspect. The rest of the code I've got under control.
02:57
@rlemon nice that's worth it imo
also you get a year warranty through them
03:31
ugh. I just deleted my config files and my only backups are on a drive at work
I suppose that means I'm done coding for the night?
!!diretide or riot
@david riot
 
2 hours later…
05:14
Hi All
@SnehaGoswami Welcome to the JavaScript chat! Please review the room rules. Please don't ask if you can ask or if anyone's around; just ask your question, and if anyone's free and interested they'll help.
Thanks @CapricaSix , I have goine thorugh rules. My question is basic, the below click here link does not work in IE
1 message moved to Trash can
@SnehaGoswami Please don't post unformatted code - hit Ctrl+K before sending, use up-arrow to edit messages, and see the faq.
function checkWin() {
    if(popupWindow.closed)
    {
        document.getElementById('alrt').innerHTML='<strong>If download is not successful,<a href="http://ABC/Home/DownloadDocPage"> Click here</a> to download </strong>';
    }
}
05:48
Anyone knows topological sorting here? I am looking for sample data with which I can sort this way...
@deostroll this way ?
06:12
topologically
06:52
For the Bookworms :)
http://area51.stackexchange.com/proposals/104465/books-and-bookworms?referrer=aJeOXMMOcGUDnmaiHQ0OiQ2
 
2 hours later…
08:30
Yay, revenge downvotes when you tell someone not to use eval...
@SantanuSahoo Welcome to the JavaScript chat! Please review the room rules. Please don't ask if you can ask or if anyone's around; just ask your question, and if anyone's free and interested they'll help.
1 message moved to Trash can
@SantanuSahoo Please don't post unformatted code - hit Ctrl+K before sending, use up-arrow to edit messages, and see the faq.
let first = {name:{
	FirstName: "Foo",
	SurName: "Bar"}};
	let last = {name:{
	FirstName: "Baz"
	}};
	let person = Object.assign( first,last);
	console.log(person);
i am expecting the person object should have "SurName" also but it is not there
any help ??
@ArnavYagnik Welcome to the JavaScript chat! Please review the room rules. Please don't ask if you can ask or if anyone's around; just ask your question, and if anyone's free and interested they'll help.
@SantanuSahoo You're overriding name with the second argument
08:45
so i need to give all property of name.
@SantanuSahoo you should do Object.assign({} , first.name , last.name)
Object.assign works only for level1 nesting
for merging nested object like your's you can use merge function from lodash library
@Cerbrus next time
@BenjaminGruenbaum Next time?
this is what i need @ArnavYagnik
Thanks a lot
cheers!
08:52
Is there any third party tree directive with checkboxs in angularjs. I had tried angular-ivh-treeview but its take much time to load data...
@codeZero Welcome to the JavaScript chat! Please review the room rules. Please don't ask if you can ask or if anyone's around; just ask your question, and if anyone's free and interested they'll help.
@Cerbrus election
election results are out ?!
Ah yes, I'll just have to be patient :D
good luck Cerbrus
Aaron Hall was sure to win ...for some reason lot of people like him , I am thinking his hair
09:09
@codeZero Yes, yes there are
anyone have a script to turn a tar.gz to tar in unix?
@heliotrope Welcome to the JavaScript chat! Please review the room rules. Please don't ask if you can ask or if anyone's around; just ask your question, and if anyone's free and interested they'll help.
@heliotrope gunzip would be a start
cool. just did that with the --keep flag
also, remind me never to work with clients that need help backing up godaddy sites
@OliverSalzburg can you sugges any?
09:24
does anyone else wanna b**ch about godaddy? the backups through cPanel are unreasonably huge.
@codeZero No. Just try all the ones Google spits out. There are like 3 or 4
@heliotrope You have a client who has backups. That's already quite the privileged position!
@OliverSalzburg godaddy makes backups of the home directory. so i have backups where there are subdirs of the last 5 backups. its software gore as a service.
09:58
Short question; I need a polyfill for promises in the browser. I want something as minimal as possible, because size matters. What is the current go-to promise lib for polyfill purposes (hold off bluebird for now)?
good morning!
10:11
Hii guys I have 2 frames in a page in two diff div one having width 80% and the other having 20% and they are placed side by side. Now I want that when the page size decreases or approaches to mobile size then the div with width 20% comes to the bottom of the page that is exactly below the previous div
> because size matters
@OliverSalzburg thanks buddy!!!!!! I'll look into it.
css vs scssc vs another taste I forgot... which one do you usually style in ?
10:21
@Mathematics SCSS
@OliverSalzburg you are right
@OliverSalzburg does it really help over CSS
@Mathematics Yes. Massively
Once you start using it, you will never look back and refuse to work any other way
@OliverSalzburg are you aware of converting CSS into SCSS automatically :)
@Mathematics SCSS is a superset of CSS, so all your CSS code is valid in SCSS
Everything you do from there is an optimization of your existing styles
@OliverSalzburg yes I understand that but you know SCSS is more smart
10:27
I'm not sure how much I would trust any automatic conversions that try to optimize the code
Yeah, I did it by hand when I started moving to SCSS
That helped me learn a lot
^makes sense
guys, i have to implement a class with a property recipes that has to be an array and it has to be hidden, does anyone know how to make it hidden ?
@shago just add hidden to the html element like so <p class="ajaxinfo" hidden></p> i think this only works in html5 though
it's not about hidden html elements, i think it's about encapsulating the variable
10:47
@Shago What do you mean by "hidden"?
You probably want Object.defineProperty and set enumerable to false
1 message moved to Trash can
@Shago Please don't post unformatted code - hit Ctrl+K before sending, use up-arrow to edit messages, and see the faq.
var a = ['w', 'y', 'k', 'o', 'p'];
var iterator = a.values();
@MarinTakanov Welcome to the JavaScript chat! Please review the room rules. Please don't ask if you can ask or if anyone's around; just ask your question, and if anyone's free and interested they'll help.
Why this doesn't work in any browser?
And at the official Mozilla Foundation website says it's all fine
https://developer.mozilla.org/en/docs/Web/JavaScript/Reference/Global_Objects/Array/values
@MarinTakanov refer the browser support in the same link
11:02
Oh... they have replaced .values() with entries()... They should update their documentation on EC6 :)
@SankarRaj thanks
11:19
EC6?
Damn, we're still on EC2 over here!
probably because the documentation is stable
Hello
How do I tag a link in code comments in javascript?
/**
 * Code used from bl.ocks.org/tomgp/6475678
 * @param {Object} jq
 * @param {Object} d3
 */
For example how to tag the link in comment block? Is there some tag for links?
@Vlad @link or @see maybe
It really depends on what tool you're using to interpret the docs
Aptana Studio 3. Gonna check
In preferences where could I find configuration about comments?
I see they are automatically generated when I type /** and press enter
11:36
search on google
Yes but I don't get what I want. It seems I search wrong thing
@Abhishrek Oh, jeez, this is so sad :/
Aptana is based on Eclipse. Somebody knows how to configure comment blocks/tags in Eclipse?
how about PyDev?
12:13
@Vlad I'm still not really sure what you're trying to achieve
How is a setting in Aptana going to change if and how something is a link in a JSDoc?
Like, how do you even define a link in your context and how do you want it to behave in what medium?
Like, if you just want to be able to click on it in the IDE and the browser should open, then maybe you don't have to do anything. At least in WebStorm I just have to hold CTRL and click on a URL for that to happen
Specific JSDoc (and derivatives) markup is usually only relevant if you want to extract and render that information into another medium
you guys work on untyped codebases right
what do you do if you get into a new codebase without type annotations
how do you figure out what returns what and takes what?
We read the code or/and debug the function.
@MarinTakanov The code is working, so why should I debug it? By "read the code" you mean you read all the possible paths and what, do you keep notes of what gets returned?
I'm scribbling signatures of functions on a piece of paper now
Well, by "read the code", yes I meant that. Usually a function must not return different type of variables. If this is the case, this is not a standard function.
@MarinTakanov what do you mean by a "standard" function?
Also sure, I can read it once, but then I'll quickly forget what was supposed to go where
12:26
does anyone understand this code ?
var app = app || {};
(function(recipeBook) { var book = new recipeBook.book(); }(app));
A function that returns only an integer or only a string and not sometimes returns integer , but sometimes return a string.
@MarinTakanov Well I have a function that returns multiple values at once
it's kinda hard to keep track of what each of those is
different type of values or just different values with the same type
@MarinTakanov a bunch of different values with different types. It's not in javascript.
@Shago Yes. At least one person: The person who wrote it.
12:29
@BartekBanachewicz If it's undocumented/non-annotated you should start by being glad to have fired the previous maintainer, and then the only thing you can really do is go about it the long way, or pass the functions through test units to give a rough idea first
@BartekBanachewicz Read the documentation
@Shago var app is assigned new object if no variable app exists on the current scope, then the app variable is passed as parameter to the IIFE, so recipeBook is actually the passed app variable. (someone correct me, if I wrong)
i just don't understand how recipeBook has a book() method ?
@OliverSalzburg there's none for this part of code
@BartekBanachewicz No tests either then, right?
12:31
@OliverSalzburg I was searching the config options for comment tags to see how are links tagged. So when I generate documentation I know where to click and see from where the code was used from. But I couldn't find the configs in Aptana. Only PyDev section has comment settings.
@OliverSalzburg oh no there's plenty of tests
so you're saying that lack of type annotations/docs in dynamic code is universally bad?
@Vlad So, what documentation generator is used?
as in, it should be my priority to add them ASAP?
Is there anyone who'd disagree with that?
(it's in Python 3 btw)
@BartekBanachewicz it's a good practice, yes
Um, not a JS question, in UK, is it okay not to send any gift along with the xmas card ?
12:32
A regular bartek would continue trolling the dynamic typing into oblivion
but it's too real to be funny (As in, I really need to fix up this code)
I dunno, if you have tests, it should be pretty clear how all the code is supposed to work and what interface is expected on the objects that are being passed around
@OliverSalzburg As far as I know Aptana is Eclipse underneath. In PyDev Docstring settings its selected Sphinx, but there is option EpyDoc. If this helps a bit
I'm considering this atm
If a function expects an argument named foo and I access foo.bar in the function, then I already know all I need to know about the object. I don't care if it's an instance of an IFooInstructionSetContainer
@OliverSalzburg it's kinda annoying to have to go to tests just to see what goes where
@OliverSalzburg but that gives you just one example usage. It doesn't really tell you what to expect and what the invariants are.
WTB more languages with optional typing
12:37
@FlyingGambit to where?
the typing module looks pretty nice though
@OliverSalzburg there is eclipse plugin JAutoDoc which allows you to edit comment tags but not sure if it is the same for javascript :))) jautodoc.sourceforge.net
Not the end of the world though :)))
@Shago consider the following code exists:
class RecipeBook {
    constructor() {
        return {
            book: function() {console.log('New book is created'); }
        }
    }
};

var app = new RecipeBook();
@FlyingGambit Yes haha, gifts aren't mandatory
@MarinTakanov Ew, no
book doesn't exist because you haven't instantiated the class.
I´m creating a rest api with express which will be used by a SPA (react). The Auth is done using passport. At some point I have to filter data according to the users group. This group could I also place in the passport object req.user . Would u send such information from the front-end to the backend or would you just as described above fill the req.user object with such information?
because I could link this information with the session that is created during the auth process
12:47
btw
are there any news about type annotations in ES7?
not happening
@BenFortune Usually this is a code smell, because who the heck instantiate like this
var book = new recipeBook.book();

The only way someone could do something like this is if the constructor returns an object who have book as a function.
node modules do that kinda stuff all the time
@MarinTakanov But you won't hit the constructor, because you're not calling new RecipeBook
and new is applied to book not recipeBook
12:51
Actually I did after I finished the class method :)
@littlepootis really?
Wait, was your code meant to compliment Shago's code or have you rewritten it to suite him?
ahoy hoy room
Just to suite his code, but it's a terrible approach
12:52
@rlemon found a bug in robogist, sent a PR
@BartekBanachewicz ES7 has already been released. The chances of type annotations ever coming to ES is slim to zero.
@bitten To a person in UK
@BenFortune Good to know, thanks :D
There were a few proposals, iirc.
user6820627
Do you still remember Pokemon Go?
I member
Member chewbacca?
12:55
pepperidge farm remembers
user6820627
It is dead now. Pokemon Go's life is so short. But AR still alive.
Pokemon Go doesn't deserve to be called AR
user6820627
You mean Pokemon Go is just a bunch of GPS crazy numbers and it shows a Pokemon at a fixed position on the screen for us (AR mode) to catch?
user6820627
If so, agreed.
it's a cheap overlay and doesn't work well
13:01
Go used AR as a battery-draining gimmick.
the pokemon themselves do not do anything with the reality they're overlayed on
user6820627
Agreed. Crappy AR. And there is a no AR mode (wait, what?!).
@rlemon hahahahahaha
is that tycoon world?
Planet Coaster
crowds use fluid physics
so you can really make a splash
Looks fun, haven't played anything like that since the ps1
13:05
RTC1/2 on PC for me
long time ago
Wow, recommended 12gb ram
user6820627
@BenFortune i don't have that much ram
@littlepootis super sad
python type annotations look pretty decently implemented
I have to try out mypy
user6820627
@BartekBanachewicz you have to use Emscripten
I am not running in the browser
13:11
@prasanthrubyist Welcome to the JavaScript chat! Please review the room rules. Please don't ask if you can ask or if anyone's around; just ask your question, and if anyone's free and interested they'll help.
1 message moved to Trash can
@prasanthrubyist Please don't post unformatted code - hit Ctrl+K before sending, use up-arrow to edit messages, and see the faq.
yeah okay
print_country('customer_account_cus_acc_country',1);
$('#customer_account_cus_acc_country').change(function() {
print_state('customer_account_cus_acc_state',this.selectedIndex);
});
I want to display already selected state in edit page
I'm getting country but I can't get state
> Cannot read property 'redirectTo' of undefined
	if( req.session && res.session.redirectTo ) {
		path = req.session.redirectTo;
		delete req.session.redirectTo;
	}
hwat?
how is it even evening?
this, and where I set the session value, are the only two refs to redirectTo
I'm very confused
13:27
@rlemon My guess: The error originated from a different piece of code?
3 mins ago, by rlemon
this, and where I set the session value, are the only two refs to redirectTo
Maybe you forgot to restart the process after you added the safeguard :P
> Cannot use 'in' operator to search for 'redirectTo' in undefined
if( req.session && 'redirectTo' in res.session ) {
I changed the code to this.... what in the good fuck
how is it even running that?
FUCK ME
@rlemon req vs res
req/res
god dammit
13:29
😃
We prefer to shorten them to r for request and R for response. To avoid any confusion like that. It's also faster to type
win-win
good god, don't code before 9am
dear sublime text: why would you make replace ctrl + h but replace globally ctrl + shift + f and not ctrl + shift + h
😒 you always confuse me on that
ugh.. seriously?! I am not with it today
> Math.MAX_SAFE_INTEGER
duh hur, I wonder why that is undefined?
:facepalm:
13:46
how can I convert this array into a JSON object :S
JSON Object isn't a thing
JSON String?
I need something like above
that's just an object
I tried parse and stringify but nothing converts it
you want implicit re-organization?
13:48
yes
that doesn't exist
so that I could use it with this - github.com/dabeng/OrgChart
unless you write it
so I will have to do foreach...
no other choice :( ?
no other choice
13:49
oh noooo, not even something like trump ?
@BenFortune lol fml... man.. not my day, I just synced up directories... forgot to omit the user uploads directory. cleared my uploads.
😒
@rlemon hold on for a second
when I view Response of chrome dev tools... I get the exact structure I need, there must be some way :?
don't want to reinvent the wheel
@Mathematics "JSON object" isn't a thing. JSON describes a standard for you to pass data as Strings which can then be parsed back into some other data, in your case it will be parsed back into a JavaScript Object
so if you already have the object, JSON.stringify it to get your JSON
@rlemon I totally agree with you, but I am having problem with explaining my problem, let me reword it
13:58
@rlemon Haha, for what?
@BenFortune the store. it's all 'demo data' but still.
I re-wrote most of it last night, but deleted my config.json file by mistake
so had to upload / start it once I got to work and got my backup drive
... and my copy here ofc doesn't have the user uploads...

« first day (2230 days earlier)      last day (2943 days later) »