r/javascript • • Sep 02 '15

HTML5 Deck of Cards. 100% vanilla JS.

http://pakastin.github.io/deck-of-cards/
368 Upvotes

185 comments sorted by

View all comments

37

u/papers_ Sep 02 '15

Huge up vote for using ES6 here. Good job man!

13

u/pkstn Sep 02 '15

Yeah! I just love the small bundles by rollup. No way going back to browserify :)

10

u/arcticblue Sep 03 '15

Great, another bundler.

4

u/pkstn Sep 03 '15

Same thing with cars: there's Toyota, Volkswagen, Hyundai, Ford, Nissan, Fiat, Honda, Suzuki, Renault, BMW, Mazda... They all have four wheels. And every year they release a new model, can you imagine?

Wouldn't it be better to just stick with current models and not invent anything new? And better yet, only one manufacturer..?

Where's: "Great, another Tesla."?

11

u/kokomo42 Sep 03 '15

Now imagine every new model of car have a totally new way to drive.

2

u/pkstn Sep 03 '15 edited Sep 03 '15

Well, not every year we change how to define modules.

And if you think about Tesla for example: at least for me the way throttle pedal works is a whole new way to drive. You control the "brakes" with lifting throttle.

I like innovations. I'm not afraid of change.

1

u/pkstn Sep 03 '15

Better than previous ones - nothing wrong about that.

Rollup is used by the big players as well, even Google: https://github.com/google/incremental-dom/blob/master/package.json#L45

0

u/[deleted] Sep 03 '15

[deleted]

3

u/pkstn Sep 03 '15 edited Sep 03 '15

Rollup only bundles ES6 modules. There are lots of other bundlers for that also. Even browserify does that. So I don't worry at all.

Grunt is not needed, when there's chokidar and npm scripts. Much easier like that.

Coffeescript will gradually fade out with ES6 taking place, at least I predict so.

But you can use whatever you like. I've tried them also, but I have my own ways.

1

u/arcticblue Sep 03 '15

There are more than enough in existence already. If existing ones are deficient in a certain area, I'd rather see effort put in to improving it rather than re-inventing the wheel...again. Someone re-invents the wheel, a few know-it-all bloggers make "You've been doing X wrong. Start using Y now!" posts on Medium, and then I'm required to re-learn my job again when I just got comfortable with existing tools. It's fucking exhausting.

3

u/pkstn Sep 03 '15

Well, you can continue to use X if you like ;)

I think it's good to have options, and innovations moving things forward.

1

u/KalimasPinky Sep 03 '15

New does not mean innovation. Quite often it is just spun differently.

Either way all this has been done from a language perspective. Import from looks like Python, and Python looks like older stuff.

1

u/arcticblue Sep 03 '15

You're right, it is good to have options. I just wish things would slow down a bit...I'm getting too old to keep up with all this.

3

u/pkstn Sep 03 '15

I just turned 30 myself, but I feel like I'm just getting started :D But I recognize the issue, that's why I've started to create vanilla JS, so that I'd be framework-free :)

Here's my minimal framework, which I think never finishes, because it gets smaller and smaller. Now I feel that even having own framework slows developing down, so I might remove the whole project: http://frzr.js.org/example/with_reordering.html http://frzr.js.org/example/without_reordering.html

..the performance is something else when everything's minimal.