« first day (2794 days earlier)      last day (2169 days later) » 

2:26 AM
💩
 
3:16 AM
morn
 
 
2 hours later…
5:30 AM
toLocaleDateString() returns date format like yyyy/mm/dd anyone knows how to change the format to dd/mm/yyyy?
 
 
1 hour later…
6:37 AM
How do I vertically center both divs ? codepen.io/anon/pen/mKRKqR
 
 
2 hours later…
8:12 AM
Hey guys, im currently an intern doing backend with nodejs and mongodb.
 
I had a question about production performance, right now all the code and stuff I am writing, I am testing it locally. I'm just afraid that after launch if it will be able to handle a lot of requests at once, or mongoDB wont be able to create objects fast enough etc.
Do you guys know of any resources to learn this? (dont know what to call it). or good practices to ensure it can handle
 
I will let other wise men answer this
 
8:29 AM
Hi guys anyone knows how to implement ifelse with promise without creating something like promise hell ._.
 
 
2 hours later…
10:38 AM
Is web assembly on briwsers mainly used for cpu intensive tasks like media playing?
 
hey what is this icon called, I am trying to find it in font awesome
 
 
2 hours later…
12:13 PM
I have an array with 10 items in it.
Is it correct that Angular should create 10 empty elements even tho none of them are matching?
<div *ngFor="let item of items">
  <div class="item-name" *ngIf="item['.tag']==='test'">{{item.name}}</div>
</div>
Now I see 10 empty divs with this inside:
<!--bindings={
  "ng-reflect-ng-if": "false"
}-->
 
yes
you probably want the ngIf on the top div, if you only want matching divs
also, you probably meant to do item.tag or item['tag'], but that might be intentional
even better might be to create a getter for testItems which is filters items, and use that instead. Depends on where you want which parts of your logic
 
But if I have serval divs inside the loop, all with different conditions, then It's not possible to move the ngIf to the top div right?
Cause all will have different ngIfs
The item['.tag'] is correct, ask dropbox why they made it like that :)
I have to look up this getter thing you are talking about
 
if you want it clean, then you abstract it out
you create getters, or functions, to check for conditions of each item
and you put the logic in the ts part
and just keep descriptive names in the template
 
Thats how I would have want it, but is that really the angular way? (Just learning angular)
I mean, how cool is this for etc.
<i class="material-icons ">{{item['.tag'] === 'file' ? 'insert_drive_file' : 'folder'}}</i>
Can you show me, how would it be done with logic in ts and descriptive name in the template on that simple line
<div class="item-name" *ngIf="item['.tag']==='test'">{{item.name}}</div>
 
1:21 PM
hi i'm building a cli
where if the command is invalid i say cli.showHelp(1)
while writing failure test case for this using sinon
i keep getting
TypeError: cli.showHelp is not a function
test('[commandl] [run] [error]', (assert) => {
  const cli = { input: ['wrongCommand'] };
  const context = 'something';
  cc.run(cli, context)
    .catch((err) => {
      assert.equals(err, 'Command not valid, use --help for a list of valid cluster-control commands.');
    })
    .then(() => assert.end());
});
and the cc file is something like
what is wrong in this?
 
1 message moved to Trash can
@TapasweniPathak Please don't post unformatted code - hit Ctrl+K before sending, use up-arrow to edit messages, and see the faq.
 
  if(valid){
    const run = require(`../lib/${command}.js`).run;
    return run(cli, context);
  } else {
    console.error(`ERROR: ${cli.input[0]} is not a valid command`);
    cli.showHelp(1);
}
ok @CapricaSix
i was initially returning a promise in the second code snippet
something like
  if(valid){
    const run = require(`../lib/${command}.js`).run;
    return run(cli, context);
  } else {
    return Promise.resolve()
      .then(() => {
        console.error(`ERROR: ${cli.input[0]} is not a valid command`);
        cli.showHelp(1);
      });
  }
};
the test fails with TypeError: cli.showHelp is not a function
not sure why
 
 
1 hour later…
3:36 PM
@MadaraUchiha solution: prefer better APMs to AI
 
APMs?
 
Armed Penguin-Monkeys
 
@MadaraUchiha how would you call AI? it's an application performance monitor
 
@BenjaminGruenbaum Oh, you mean like KissMetrics?
 
3:54 PM
@MadaraUchiha no, that's analytics, I mean like New Relic
Or like dynatrace and shit
 
4:08 PM
ohai me loves
 
Ohai
 
I'm never taking a train to krakow ever again
delays delays everywhere
 
Looks so scenic, though
 
@BenjaminGruenbaum hai
question: i have a directory in node_modules which I'd like babel-transform to run on. but only that directory, no other ones.
has anyone run into a similar problem?
 
4:23 PM
@KamilSolecki you're not my love, wife
 
@johnmarinelli so, specify it in include with a loader in webpack or whatever?
 
@BenjaminGruenbaum ah okay, i didn't know if it would override the exclude statement. i'll try that
 
 
2 hours later…
6:04 PM
Hiya guys. Have anyone gotten this messages when trying to create a react app?
let notifier = require('update-notifier')({pkg})
^^^
SyntaxError: Block-scoped declarations (let, const, function, class) not yet supported outside strict mode
 
Guys, this is looping forever and ever... is it something wrong with the element or the function?
<img id="item.id" *ngIf="thumbs(item.path_lower, item.id)">
 
 
1 hour later…
7:11 PM
How can I run this one without a click event?
<img (click)="myFunction(param1, param2)" width="25" height="25" [id]="foo">
 
8:04 PM
hi i want to RegExp(nameFilter) on something like abc-anything-parachute
having my const nameFilter = ^${prefix};
what should be prefix
prefix = abc-.*-parachute doesn't seem to work
okay np, it worked
thanks anyways
 
Hi everyone
 
8:31 PM
i'm  using the aws s3 node client.  i'm noticing that the callbacks are just not being fired

let a = client.listObjects(params, () => {
	console.log("here")
})
"here" is never logged
 
user1596138
8:56 PM
Bad pun of the day
 
user1596138
I'll get my gf a "I <3 JS" bumper sticker but that's actually my initials 😂
 

« first day (2794 days earlier)      last day (2169 days later) »