« first day (2238 days earlier)      last day (2713 days later) » 

8:00 PM
@ssube :(
 
I kinda like jQuery but I heard bad things about performance @bwoebi so I just avoid it at all costs
 
well fuck
 
@bwoebi you could also learn COBOL
it sucks and nobody uses it anymore because there are better options, but like jQuery, it still exists
 
ColdFusion is for expert devs
 
@lix That's the problem with it … unless you know exactly what you do, you end up with shit ultimately
 
8:01 PM
@bwoebi nah, you end up with unreadable shit either way
 
@SterlingArcher real devs laugh at your old technology, spend nine months building everything in <enter new cutting edge language / framework> then spend the next four years turning it into something old and usable
 
unless you're doing the most trivial things possible, jQ falls apart real quick
 
angularJS ftw
 
@lix Typescript changed my life ;)
 
@ssube usually yes, I agree
 
8:02 PM
Typescript made me want to kill myself
 
@SterlingArcher lol, that's so old
 
No wait that was coffeescript
 
@Cedric classic .net / PHP guy here, since using javascript I've just avoided making properties
 
@SterlingArcher you know that Angular 2 is written in TypeScript ?
 
8:03 PM
@lix wat
 
@lix huh?
 
I meant to put java
 
eh, i look at typescript and just consider it to be another coffeescript
 
new people need to use TS before they use JS, especially if they came from Java/C#/C++
 
and dismiss it
 
8:03 PM
but yeah I used typescrit and was look oh look back to writing int and string on things
 
@KevinB it's the opposite, it's like Flow. It's just a type checker.
with some babel mixed in
 
TS looks really nice, if you're into that kinda thing.
I just don't see the need in JS
 
its really good
 
why
 
it's really nice when you have large (100+ class) apps
 
8:04 PM
@rlemon you just said what I was trying to say :-)
 
but, hey, if it's for you it's for you
 
makes it real easy to not screw up what you're passing between modules
 
@rlemon It depends on the scope … if you do your small scripting and use a little big framework … then you surely don't need it
 
if you can write JS without lint, you can write it without types
 
@lix objectively it does make the code better .. but I've been lookin at shit for the past 20 years now
 
8:05 PM
they're pretty much the same
 
@rlemon HAHAHAA
 
@ssube well, that's not hard…
 
I just personally think that If I'm going to be unit testing my code hard anyways It seems like more overhead for something that does the same thing
 
@bwoebi usually, no, but sometimes lint will catch something that you've been looking at for hours and didn't see. Same with types.
 
@lix unit tests don't help the next dev who is trying to update your modules. remember, we write code for other people to read
 
8:06 PM
TS/Flow, ESLint, everything in that family is just a static analysis/yell before it explodes tool.
 
lol
 
use them if you hate explosion, don't use them if you hate yelling
although there's a good chance that without lint and SA, your boss will come yelling at you, so fair warning
 
@ssube I hate loud things :-P
 
Makes sense it's where my inexperience kind of shines @rlemon
 
I totally get the point and the benefits of TS. I just don't care to use it.
 
8:07 PM
@bwoebi well you're just screwed both ways then
 
@rlemon +1
 
@rlemon yeah, but your code works without
 
I am happy with Flow for now :D
 
so you're probably not missing much
 
if I worked in a team, or had to pass off modules to other members, I totally would be all over TS or something like it.
 
8:08 PM
@rlemon Dealing with jQuery you have a passive bonus when writing sane javascript.
 
the only real problem with not using those tools is when your reason is "they throw too many errors, I don't want to clean up my code, TS sucks"
 
@Bartek ^
 
i don't use it because... i don't want to learn it. I write so little javascript on a daily basis that i don't see it worth the time
 
Just use TS man :D (I'm sure we have told you this thousands of times)
 
@ssube TS dont suck bud you're jsut to lazy ;)
 
8:09 PM
I do lint all of my js tho
 
I might be crazy, but I enjoy writing JavaScript as it is. I don't want types in my js, I don't want additional strictness
11
 
@Cedric that's my point
 
@rlemon Types, please yes. Strictness, no thanks.
 
@rlemon you are not crazy, same here
 
@ssube but at the end typescript saves you times ;)
 
8:09 PM
@rlemon I do. I get off on them. I turn on every warning level there is and warnings as errors.
 
you can always use
 
@bwoebi well, types without strictness is kinda what we have today
 
const varString = funcCloth();
 
linting helps me catch my typos
 
although more seriously, coming from C/++, when I started JS and functions weren't telling me what type of data they expected, it really screwed me up
 
8:10 PM
This entire conversation has been more educational than my last 7 lectures at university..
 
@rlemon same man
 
@lix s/lectures/years/ ?
 
I mean I will use them for PropTypes, but nothing other than that.. however I will 100% admit I haven't given TS a fair shake at all
 
it's really nice to have that tooltip that says "3 arguments, one number and two strings, etc" and losing it is confusing af
 
I just feel its like wtf was that other JS type language...
 
8:11 PM
@Loktar How do you write proptypes in Es7 ?
 
heh, i like that feature in coldfusion
 
damn I can't think today
 
@bwoebi Client side scripting / 12 lectures total/ 4th year
 
when you properly document your component methods
 
it was so popular
 
8:11 PM
types have some cost when you set them up, and there are occasional hoops, but especially recently most of the errors I've gotten were actual code smells
 
and then fell out of favor..
and you have to rewrite all your stuff now
 
@rlemon I mean like you can type things and when these things assigned something, these are tried to be coerced to the type of it … it'll just complain if it's totally incompatible like a function to a string (I mean … you can have [Object object] or such, but that's shit)
 
I can point to a few files where TS warned me that something was janky, I hacked around it, and later had to refactor the file because it turned out I was wrong
 
@PropType('foo', String)
class Bar extends Component{


}
 
pull the cfc up in the browser and get all the methods listed out with arguments and expected types, return types, etc
 
8:11 PM
oooh nice @Abhishrek
I just do this, one sec
static propTypes = {
    businessName: React.PropTypes.string,
    notes: propTypes.observableArray,
    tags: propTypes.observableArray,
    assigned: React.PropTypes.bool,
    assignedUser: React.PropTypes.string
};
 
I like that thing.....
 
super simple example
 
but, it gives me a headache, most of the times
 
god what was that hipster script called?
 
React.PropTypes is redundent
 
8:12 PM
That had classes?
 
ClassScript
 
@Loktar coffee? live? native?
 
coffee!!
yes thank you lol
I worry about getting into a Coffeescript situation using TS
 
coffeescript is the worst
 
you can tell coffeescript was bad and people just used it because it was cool, cause now that it's dead, they're mostly happy
TS at least is clear about what they want to do instead of just being perl/ruby
I'd drop TS pretty quickly if Flow actually worked well
 
8:14 PM
@Loktar btw IDK if you are using sequelize
but their ES6 / ES7 effort is gorgeous
 
with the updates to c#, and the 'growth' of TS, I feel like it is a great combo together. I always get this lurking c# feel when reading ts
 
it's supposed to look like C#
if you think C# is an exceptionally well designed language, you'll probably like TS
 
never used it
 
I work in .net shop
I've been asked a lot about TS
and why we don't use it
 
I think c# is a well designed language. I don't know how exceptional it is
 
8:15 PM
basically it comes down to not wanting to be stuck holding the bag lol
 
that explains why you sort of like TS, then, lemon
it's a relative sliding scale
 
The reason I'm enjoying javascript atm is because I feel like a hacker using it compared to just average on C#
 
@ssube ohh I totally like the idea of TS. I just don't want to use it myself. that attitude may change one day
I said the same thing about React
 
class MyAPI extends API{
      @authenticate()
      async get_users({params, user}){
          return await request.get('/someother/call');
      }
}
 
and Node for that matter
 
8:16 PM
Not a fan of node?
 
@lix wow
 
I was not a fan of Node or React at first
 
@lix no, on the contrary
 
@Loktar Thats JS ;-)
 
using them, I see the value in React
 
8:17 PM
I was not a fan of node or react when I was presented them
 
Node is actually kind of bad
 
now I love node
 
you could do the same thing much better now
 
@Abhishrek man, I need to use/learn async await, ect.
 
and React is making more and more sense
 
8:17 PM
@KendallFrey Please take that statement with a pinch of salt :-)
 
as I've been writing my terminal wrapper for React, I'm understanding their choices much more
 
@ssube node is good in the sense that I can use JS for everything now
 
@KendallFrey LOL glad someone responded
 
@Loktar if you are using babel just start writing code in them
 
I had some rude comment typed up and just was like nah, don't be mean (was going to be jokingly mean ofc) I'm a nice guy, the nicest, we have the nicest people in the chat.
 
8:18 PM
@rlemon yeah. The modules it exposes aren't great.
 
@Abhishrek yeah I need to go look at a tutorial or something, using babel even stage 0
 
If you have used async/await in C#, you need not worry. Things (that are promises) just work
if not ...
 
@Loktar I have some pretty decent examples with it
 
@rlemon Yeah, now that we have defacto node in the browser, we could finally start to clean up the cruft called server-side node and nuke it from orbit.
 
I'd love to check them out
 
8:19 PM
actually
 
gist: 3f15cfd8a00f315dd87dbd28476872e1, 2016-12-01 20:20:03Z
import {Buffer} from 'buffer';
import fs from 'fs';
import path from 'path';
import {Stream, Readable, Writable} from 'stream';
import {Url} from 'url';
import NotImplementedError from '../error/NotImplementedError'
import Transport, {TransportOptions, ReadParams, WriteParams, WriteData} from './Transport';
import PromiseUtils from '../utils/PromiseUtils';

export type Read<T> = (path: string) => Promise<T>;
export type Open<T> = (path: string, options: {}) => Promise<T>;
export type Write<T> = (path: string, data: T) => Promise<void>;
export type PathOptions = {
  [key: string]: string;
  root: string;
};
export type WriteParams = {path: string, data: string};
export type FileTransportOptions = TransportOptions & {
  encoding?: string,
  paths: PathOptions,
  buffer?: {
    read: Read<Buffer>,
    write: Write<Buffer>
  },
  stream?: {
    read: Open<Readable>,
    write: Open<Writable>
  }
};

export default class FileTransport extends Transport {
  protected _paths: PathOptions;
  protected _bufferReader: Read<Buffer>;
  protected _bufferWriter: Write<Buffer>;
  protected _streamReader: Open<Readable>;
  protected _streamWriter: Open<Writable>;

  constructor(options: FileTransportOptions) {
    super(options);

    const {
      paths,
      buffer,
      stream
    } = options;

    if (buffer) {
      const {
        read = PromiseUtils.wrap(fs.readFile),
        write = PromiseUtils.wrap<void, string, Buffer>(fs.writeFile)
      } = buffer;
      this._bufferReader = read;
      this._bufferWriter = write;
    }

    if (stream) {
      const {
        read = PromiseUtils.wrap(fs.createReadStream),
        write = PromiseUtils.wrap(fs.createWriteStream)
      } = stream;
      this._streamReader = read;
      this._streamWriter = write;
    }

    this._paths = Object.assign({}, paths);
  }

  async bind() {
    return this;
  }

  async release() {
    return this;
  }

  /**
   * Return the most complete path possible, by resolving the given path with
   * its host path or the root.
   * 
   * @TODO add a security flag to prevent absolute paths and require a base
   */
  resolve(url: Url): string {
    if (url.hostname) {
      const base = this._paths[url.hostname];
      const partial = url.pathname.substr(1);
      const absolute = path.join(base, partial);
      this._logger.debug({absolute, base, partial, url}, 'resolving path against base');
      return absolute;
    } else {
      return path.resolve(this._paths.root, url.pathname);
    }
  }

  async read({path}: ReadParams): Promise<Readable> {
    const absolute = this.resolve(this.parse(path))
    const stream = fs.createReadStream(absolute);
    return stream;
  }

  async write({path, data}: WriteParams<WriteData>): Promise<this> {
    const absolute = this.resolve(this.parse(path));
    if (Buffer.isBuffer(data)) {
      await this._bufferWriter(absolute, data);
      return this;
    } else if (data instanceof Stream) {
      const stream = await this._streamWriter(absolute, {});
      stream.end(data);
      return this;
    } else {
      const buffer = Buffer.from(data, this._encoding);
      await this._bufferWriter(absolute, buffer);
      return this;
    }
  }
}
 
@Loktar Wasn't a great choice of words, but hey JS is more enjoyable
 
is both a TS example and an async example and code I need to clean up some
 
@lix lol no I get it
 
8:20 PM
from what I've been working on lately
 
It's always refreshing to jump to something else
awesome ty @ssube and @Abhishrek
 
comments (especially on how to simplify it) are welcome, too
 
@bwoebi so we can go back to writing APIs with php? Hahahahahaha
 
@rlemon yes!!!! lol
 
8:21 PM
@bwoebi suddenly, all the servers are slow and hacked
 
Your in the wrong neighbourhood brother.
 
@ssube BUT BUT BUT HIPHOP AIN'T SLOW MAN!
 
@ssube Uh, Node isn't faster than PHP ?
 
@Abhishrek it is
@bwoebi PHP is faster than Java too
 
@Abhishrek nobody talks hiphop today… PHP 7…
 
8:22 PM
Why do you guys never get when I am being sarcastic
gosh
 
@ssube That's not hard either.
 
@bwoebi just like people use perl 6!
@Abhishrek bruh, look at my last two messages
 
@ssube perl? sorry, I don't remember that thing.
 
yeah sorry
 
@bwoebi it's the thing you should have shelved right after php 😉
 
8:23 PM
@bwoebi you've never heard of perl but you're sure php is faster than things?
 
i used to write a lot of perl, when i played minecraft
 
I remember having to write perl for a UO server
 
@ssube I meant that sarcastically, i.e. Does anyone still really use that for real?
 
perl is the php of the 80s
 
had to rent a book from the library to do it
 
8:24 PM
@bwoebi about as much as PHP
 
@ssube good joke
 
computercraft, and then open computers were a lot of fun... but i never actually managed to finish any of my plans
always got bored and moved on to something else
2
 
^ developer motto
 
githut.info is pretty cool, though dunno if representative
 
that point where where you're having fun, until it's almost done
 
8:25 PM
I'm sad how accurate that is :(
 
has moar PHP than Perl anyways
 
@ssube I've had to edit some perl scripts sometime, but these two chars special things drove me crazy
 
@ivarni it's pretty accurate for OSS
I'd say that PHP and Perl still see a lot (maybe most?) of their use in private.
 
@ssube Yeah, true, legacy codebases wouldn't be there
 
when your junk is that torn up, you don't usually show it to people
2
@ivarni that too
 
8:27 PM
@ssube don't I know it
😃
@Loktar dev team tried to draw Kirby
 
hahah
 
@rlemon photoshop continuity fail is painful
 
@ssube tell that to my ex-gf
 
I don't want to know
 
@ssube Red Dead Redemption
 
8:31 PM
I feel like I've heard enough of that story already
plus so many of Sterling's stories are like "oh my god, that could have been me except for [lucky coincidence]"
 
I have a UI/UX question
say I have a graph with lots of points on it
 
isn't number two of Red Dead Redemption announced?
 
clickable points
but on touch devices it's hard to click
because they are many and tapping hardly registers
 
@Mosho give em a table or something too
IMO any graph should come with a table view
 
it's a lot of data points
there's a table that shows the currently selected data point
I thought maybe a slider or sideways arrows
 
8:34 PM
scroll arrows are good, but at that point you're paginating
 
hammer.js with swipe gestures
 
jQuery with grab handles
 
DHTML with snowflakes
 
hmm I'll try some things
 
XHTML 4.01 Transitional with <font> tags
 
8:36 PM
nvm, too painful
ohh god
 
IE 6 mode with vbscript
 
nothing was worse than that markup language which shall not be named
 
I mean, we can just short circuit this race to the bottom: /P[a-z]{3,4}/
 
@Mosho show them a second zoomed view for where the fuck they want to actually tap ?
or two sliders <3
 
only from White Castle
 
8:42 PM
but then again
if its not precise
so another slider
wuth each slider
to control the unit of sliding
 
jesus there's some guy vamping trying to get me to help him with his LED strip
 
I'm voting to close this question as off-topic because the cold war started well before that. — ssube 5 secs ago
 
slightly amusing at this point
 
I, uh... found a weird question
 
@KendallFrey email?
main?
chats?
 
8:48 PM
Boo, who downvoted it?
 
@rlemon hackster.io, but showing up in my email
 
@Abhishrek idk sliders for zooming sounds tedious
 
Do I get Chic Fil A or Chipotle for dinner? Probably Chipotle, right?
 
Pop Eyes!
@Abhishrek that's a garbage UX and you know it (or, if you don't, go to Google maps and see how often you use the +/- instead of your mouse wheel)
 
I don't want popeyes shitty sludge
 
8:53 PM
@KendallFrey can you pm on that site?
there is 0 comments on your project
 
@rlemon yep
@rlemon nope nope
 
Pinch-to-zoom
 
@KendallFrey with the scope?
 

« first day (2238 days earlier)      last day (2713 days later) »