00:00:01  * ircretaryquit (Remote host closed the connection)
00:00:09  * ircretaryjoined
00:04:44  * ins0mniaquit (Ping timeout: 255 seconds)
00:05:16  <mbalho>substack: https://gist.github.com/maxogden/5104377
00:05:28  * thl0quit (Remote host closed the connection)
00:07:01  * marcello3dquit (Remote host closed the connection)
00:07:30  * marcello3djoined
00:07:59  * ins0mniajoined
00:09:32  <substack>mbalho: I'm less sure about the indexdb part
00:09:48  <substack>I think the answer to this problem is not to have a thing
00:10:06  <mbalho>substack: huh?
00:10:13  <substack>mbalho: the problem I have particularly with your approach is that your modules are tightly coupled to the pagelet module
00:10:17  <substack>it's not self-contained
00:10:29  <substack>you're exposing a constraint to use pagelet upstream on module consumers
00:10:59  <substack>whereas a better external interface would be:
00:11:00  <substack>var button = require('simple-button')
00:11:13  <substack>then you call functions defined on the button object
00:11:15  <substack>as per the api
00:11:53  <mbalho>substack: so button would have insertStylesheet and appendTo or something
00:12:05  * marcello3dquit (Ping timeout: 256 seconds)
00:12:10  <substack>if those were relevant sure
00:12:38  <substack>a module to generate *those* functions might be warranted
00:12:44  <mbalho>substack: the only use case for something liek this is the case when markup, style and behavior are all relevant
00:12:50  <substack>but not as a dependency-injected upstream constraint
00:13:40  <substack>mbalho: but the external interface seems really awkward
00:13:55  <substack>dependency injecting an ad-hoc pagelet module referency thing
00:14:21  <substack>that won't be easily consumable by people who don't give a shit that there even is a thing called pagelet
00:15:07  <substack>the point of modules is that they are self-contained and you don't need to care how they are implemented
00:15:28  <mbalho>substack: what if page just polyfilled HTMLElement
00:15:35  <defunctzombie>danger!
00:15:42  * mikolalysenkojoined
00:16:08  <substack>mbalho: modules shouldn't ever polyfill anything ever
00:16:12  <substack>except internally
00:17:17  * mikealquit (Quit: Leaving.)
00:17:24  <substack>or if there is polyfill functionality that takes an HTMLElement as an argument and returns a polyfilled HTMLElement, it should be its own module
00:17:37  <defunctzombie>indeed
00:18:01  <substack>otherwise modules will be polyfillying all over the place in mutually exclusive breaking ways
00:18:07  <substack>to the global refs
00:18:17  <substack>which breaks composability
00:18:25  <mbalho>substack: which part do you consider 'dependency injection' exactly?
00:18:35  <substack>mbalho: how you pass the `page` reference to the module
00:19:21  <substack>instead of page being a fully internalized instance
00:21:17  <mbalho>substack: ok... if you had a module that required a css class be defined in order for it to look correct and a html template for it to instantiate itself with (like the simple-button) you are referring to 'dependency injection' as the act of the module adding those 2 things to a DOM?
00:21:21  <defunctzombie>I personally liked the hack Raynos had about totally hoisting requires, but in general modules should not do any of that, they should just expose things about themselves
00:21:30  * mikealjoined
00:21:55  <Raynos>?
00:22:30  <Raynos>mbalho: your idea is crazy
00:22:35  <mbalho>Raynos: thanks
00:23:44  <Raynos>mbalho: I recommend you solve templates & Css seperately and orthogonally
00:23:49  <Raynos>I also recommend you stick to simple things
00:24:00  <Raynos>like function (x) { return DOMElement }
00:28:12  <substack>mbalho: what about something like button.appendCss('head') ?
00:28:22  <substack>or you could call that automatically
00:30:38  <substack>that's what I do here: https://github.com/substack/slideways/blob/master/index.js#L29-L39
00:30:50  <substack>unsure of this approach versus an explicit function though
00:32:37  <mbalho>substack: if web components were out i would support this level of modularity
00:33:06  <mbalho>substack: but right now cant you assume that a web page has a global set of stylesheets and a single global dom tree
00:33:16  <substack>shadow dom stuff has a lot of built-ins to make writing these modules much more robust
00:34:12  * tmcwquit (Remote host closed the connection)
00:34:20  <substack>mbalho: the issue I was raising about passing in an `page` reference is that it's a crummy external api for end-users
00:35:03  <substack>var button = require('some-button')()
00:35:08  <substack>button.appendTo(someElement)
00:35:14  <substack>is a pretty good api I think
00:35:20  <mbalho>substack: gotcha
00:35:46  <substack>the some-button module could use pagelet inside of itself to help with doing the css insertion etc
00:35:53  <substack>I think that's the write place for these libs
00:36:03  <mbalho>substack: im tryign to figure out if you can assume where styles and scripts can be inserted and just have the module define its markup container
00:36:46  <mbalho>substack: cause it sucks to have to manually copy/paste .css files and .html files
00:36:56  <substack>yep
00:37:13  <substack>but brfs can help a lot with that
00:37:20  <substack>particularly the browserify transform field
00:37:33  <niftylettuce>substack: what's your thoughts on Components?
00:37:50  * tmcwjoined
00:37:53  <substack>niftylettuce: npm is the future of javascript
00:37:54  <mbalho>niftylettuce: web components or component.io
00:38:03  <niftylettuce>mbalho: component.io
00:38:24  <niftylettuce>substack: how will it differentiate clientside vs server?
00:38:33  <substack>mbalho: I think you can make assumptions about where to insert stylesheets
00:38:36  <niftylettuce>browserify? bla?
00:38:55  <substack>mbalho: if you prepend them to the <head> body then user stylesheets can override declarations
00:39:04  <substack>so you can have customizability with good default behavior
00:39:13  <mbalho>substack: ah good point
00:40:05  <substack>and then just adopt the convention that css rules should be prefaced with the module name so it's more obvious how to extend them
00:40:28  <substack>which I've seen some modules already adopt
00:40:47  <defunctzombie>+1 to preface names
00:40:58  <defunctzombie>I made npm-css force do it if the person didn't
00:41:05  <defunctzombie>gotta keep that css shit in check
00:41:14  <Raynos>isaacs, Domenic_: EPEERINVALID ( https://travis-ci.org/Colingo/snapshot-reduce/jobs/5301323 ) is annoying with git links
00:41:23  <Raynos>i.e. its peer valid but it just uses git links instead of version numbers
00:41:24  * defunctzombieis distracted watching the bitcoin price fall like a rock
00:41:29  <substack>niftylettuce: the discoverability problem can best be solved by solving the discoverability problem directly, not be doing an NIH npm+browserify+static asset bundler
00:41:46  <defunctzombie>substack: here here!
00:41:46  <mbalho>substack: ok so maybe for bundling stylesheets there could be a module that checks of document is defined and then automatically prepends your stylesheet
00:41:53  <Raynos>mbalho: be wary of what your building
00:41:54  <substack>it's important for each tool to focus on doing one thing so it can do its one thing well
00:42:02  <Raynos>are you building some thing for web pages or web apps
00:42:13  <Raynos>web apps dont need none of this template / html / css junk. Canvas all the way bayb
00:42:13  <defunctzombie>mbalho: check out npm-css / makeup
00:42:15  <Raynos>baby*
00:42:16  <niftylettuce>substack: you mean building the modules such like underscore.js?
00:42:21  <Domenic_>Raynos: interesting
00:42:29  <defunctzombie>mbalho: the docs aren't super clear, but basically it reads a "style" field in package.json
00:42:35  <Domenic_>Raynos: file an issue so we can discuss it there and it doesn't get lost in IRC
00:42:36  <substack>defunctzombie: is all this volatility beneficial or harmful for the exchanges?
00:42:38  <defunctzombie>and then prefixes the module name to name rules
00:42:39  <mbalho>defunctzombie: ah cool i was thinking about that
00:42:50  <defunctzombie>substack: for the exchanges it makes no difference
00:43:00  <defunctzombie>substack: for merchants/merchant providers it is not good
00:43:12  <substack>yeah seems that way
00:43:20  <defunctzombie>you want a stable price
00:43:27  <defunctzombie>or one that is going up haha
00:43:40  <defunctzombie>drops hurt merchant providers because they tend to lock in certain prices
00:44:13  <substack>mbalho: yep that would be a handy module to exist
00:44:19  <substack>insert-css or some such
00:44:42  <substack>then module authors could just require('insert-css')(fs.readFileSync(__dirname + '/style.css'))
00:44:46  <mbalho>substack: some berkeley cs students were asking about hacking on voxel.js at a hackathon this weekend http://www.csua.berkeley.edu/sp13hackathon.html
00:44:50  <mbalho>substack: we should crash it!
00:44:55  <defunctzombie>mbalho: what I usually do is have the style field and then a widgets.css file
00:45:01  <defunctzombie>mbalho: which @imports <module>
00:45:06  <substack>mbalho: sounds great!
00:45:17  <defunctzombie>and that I put in the <head> and can style my app after that
00:45:36  <defunctzombie>mbalho: avoids any sort of late css loading or other nuances
00:45:42  <defunctzombie>and still get module specific css
00:45:57  <defunctzombie>it has its warts but I have found that to be pretty reasonable :/
00:46:56  * ins0mniaquit (Ping timeout: 250 seconds)
00:47:17  * tmcwquit (Remote host closed the connection)
00:48:08  <substack>defunctzombie: but module consumers shouldn't need to care that the modules they are loading have css in them is the issue
00:48:32  <defunctzombie>substack: I agree in the perfect world, but the way css works doesn't make that practical
00:48:33  <substack>most modules don't have much css in the first place so inlining the contents into the js bundle seems pretty reasonable most of the time
00:48:58  <defunctzombie>it has to do with the effects it has on the page and mistakes in applying css in time and such
00:49:04  <defunctzombie>css is weird like that
00:49:22  <substack>I haven't run into these kinds of mistakes
00:49:58  <defunctzombie>somewhere between these two approaches is better approach I think :)
00:50:06  <defunctzombie>and we will hopefully get there
00:50:09  <defunctzombie>through iteration
00:50:23  <Raynos>Domenic_: https://github.com/isaacs/npm/issues/3218
00:51:00  <Raynos>substack: module consumers SHOULD care about the modules having css
00:51:03  <Raynos>because css is a global thing
00:51:15  <Raynos>and I care about modules i consume polluting my globals
00:51:19  * thl0joined
00:51:20  * kenperkinsquit (Quit: Computer has gone to sleep.)
00:51:24  <niftylettuce>substack: why not keep node/npm separate from client side JS?
00:51:26  <substack>Raynos: when modules scope their declarations it's much more manageable
00:51:41  <Raynos>I think modules should not do CSS
00:51:42  <niftylettuce>substack: enlighten me :)
00:51:46  <Raynos>I dont know what the correct way to do CSS is
00:51:48  <defunctzombie>niftylettuce: that is worse
00:51:52  <Raynos>but its way out of scope for js & browserify
00:52:01  <niftylettuce>defunctzombie: well you have component.io then npm
00:52:01  <substack>niftylettuce: because there is a lot of overlap and huge benefits to being able to use the same modules on the server and browser
00:52:01  <defunctzombie>Raynos: +1
00:52:11  <defunctzombie>niftylettuce: you don't need component
00:52:20  <niftylettuce>substack: well what if a module only interacts with the DOM? i mean, i guess you could do server side DOM, but is that common?
00:52:21  <defunctzombie>niftylettuce: when you stop thinking about npm as being "for node only"
00:52:24  <Raynos>niftylettuce: npm >>> component
00:52:28  <substack>niftylettuce: for instance you can use scuttlebutt, dnode, tons of pure algorithmic modules from npm, etc
00:52:30  <defunctzombie>niftylettuce: yes
00:52:42  <defunctzombie>niftylettuce: I used tons of npm modules seamlessly client side
00:52:43  <Raynos>npm !== node only
00:52:53  <Raynos>npm === X package manager
00:52:55  <niftylettuce>but i mean, it itself stands for node package manager?
00:52:57  <Raynos>put anything you want in it
00:53:00  <Raynos>preferably javascript
00:53:03  <defunctzombie>niftylettuce: and yes, you can have server side dom if you want, the dom is just a magical execution environment
00:53:04  <niftylettuce>why not rename it then to JPM
00:53:12  <defunctzombie>niftylettuce: just like node is an execution environment
00:53:16  <Raynos>niftylettuce: branch and legacy reasons
00:53:20  <defunctzombie>niftylettuce: historical reasons and brand
00:53:32  * defunctzombiehigh fives Raynos
00:53:39  <niftylettuce>ppl switch overnight, hackers shouldn't care about brand
00:53:55  <niftylettuce>but i see your point
00:54:00  <defunctzombie>niftylettuce: we care about education and blogs that say do one thing
00:54:07  <niftylettuce>defunctzombie: i love "magical execution environment" haha
00:54:10  <Raynos>anyway
00:54:11  <defunctzombie>niftylettuce: it is annoying to re-write everything
00:54:12  <Raynos>just write modules
00:54:18  <niftylettuce>Raynos: yup
00:54:21  <Raynos>I'm working on http://raynos.graphics-server.jit.su/
00:54:29  <defunctzombie>niftylettuce: the way people have been writing client side js is wrong
00:54:34  <Raynos>a graphics framework thats commonJS
00:54:35  <defunctzombie>niftylettuce: the way we write it is right
00:54:37  <defunctzombie>;)
00:54:50  <Raynos>once that's done you can just write front end modules
00:54:54  <Raynos>that export and do graphics things
00:55:02  <Domenic_>Raynos: niftylettuce: defunctzombie: substack: http://www.html5devconf.com/sessions.html#d_denicola
00:55:09  <Domenic_>click the title to expand to a topic description
00:55:32  * thl0quit (Remote host closed the connection)
00:55:38  <defunctzombie>Domenic_: fuck yea
00:56:02  <niftylettuce>is there such a good common use case for doing DOM on server side?
00:56:08  <niftylettuce>maybe large multiplayer games perhaps...
00:56:11  <defunctzombie>niftylettuce: what do you mean?
00:56:12  <niftylettuce>but other than that?
00:56:16  <Raynos>I should go to that
00:56:22  <defunctzombie>niftylettuce: the DOM is just a bunch of ill defined globals
00:56:39  <defunctzombie>niftylettuce: if you stop thinking about DOM or all that crap and just thing.. "JS" then it makes much more sense
00:57:54  <Raynos>niftylettuce: ignore the DOM
00:57:58  <Raynos>there is no DOM in the server
00:58:05  <Raynos>just like there is no udp in the browser
00:58:57  <defunctzombie>Raynos: that isn't actually true
00:59:09  <defunctzombie>Raynos: chrome has udp and tcp :p
00:59:19  <Raynos>no it does not
00:59:24  <Raynos>chrome extensions have udp
00:59:37  <Raynos>chrome extenisons are NOT "the browser"
01:00:39  <defunctzombie>don't be a hater
01:01:38  <substack>Domenic_: haha my talk is focusing on modules and browserify too
01:02:58  <substack>particularly about the argument advancing splitting code up into tiny pieces and throwing them up on npm
01:03:30  <defunctzombie>substack: but but.. but.. browserify is rails like
01:03:35  <defunctzombie>substack: it doesn't promote modulatity
01:03:40  <defunctzombie>#trollolol
01:04:57  <substack>yes browserify is rails-like because it only solves a the singlular problem of bundling node-style js files
01:05:20  <substack>and not also package management, discovery, asset management, package authorship
01:05:31  <defunctzombie>hahaha
01:05:33  <substack>oh and maintaining a central registry
01:05:50  <defunctzombie>I think they defer to github for that? or a wiki or something
01:06:13  <Domenic_>substack: nice :D. i'm planning on focusing more on the npm side and less on the browserify side, but our points about small packages will probably be similar
01:06:22  <substack>there's a wiki page that is updated programmatically with the list of packages
01:06:24  <Domenic_>substack: we should probably send each other slides once we get somewhere near complete
01:06:41  <substack>Domenic_: oh I don't do slides but yeah
01:07:16  <defunctzombie>slides... psh..
01:07:22  <substack>I'm just planning on doing examples and terminal hackery
01:08:10  <substack>especially with the new pipe-able libs that browserify has been split up into
01:08:12  <substack>UNIX
01:08:37  <substack>those scripts are fun to play with on the command-line, instructive as to what browserify is doing, and make for good spectacle
01:08:53  <Raynos>defunctzombie: you going to HTML5 conf?
01:09:01  <defunctzombie>Raynos: don't think so
01:09:13  <defunctzombie>my travel plans start mid May
01:09:13  <Raynos>:(
01:09:16  <Raynos>but we need more defenders
01:09:18  <Raynos>of npm
01:09:20  <Raynos>& commonjs
01:09:26  <defunctzombie>I will defend in spirit
01:09:28  <defunctzombie>and code
01:09:30  <Raynos>theres a talk about amd
01:09:34  <Raynos>we should get some signs
01:10:06  <defunctzombie>wtf
01:10:09  <defunctzombie>seriously?
01:10:15  <defunctzombie>why is ANYONE still talking about that shit
01:10:18  <Domenic_>hahaha
01:10:19  <defunctzombie>what is wrong with these people
01:10:22  <Domenic_>picket the amd talks
01:10:30  <Domenic_>my talk does rag on amd a bit
01:10:41  <Domenic_>i gave a 20 minute version of it internally
01:10:44  <Domenic_>opened some eyes
01:10:45  <defunctzombie>its like they see what simple require statements look like in every language
01:10:47  <defunctzombie>and go.. no no..
01:10:48  <defunctzombie>fuck that
01:10:53  <defunctzombie>I want more complex
01:10:59  <defunctzombie>oh.. and I want more useless closures
01:11:10  <defunctzombie>cuase I don't have enough of those with ($) yet
01:12:15  * dominictarrjoined
01:12:35  <Domenic_>hey now don't be mean
01:12:47  <Domenic_>they just want async cross-domain loading without a build step :P
01:13:00  <Domenic_>also we haven't made wreq work that well so we don't have a strong argument for no-build-step same-domain loading
01:13:28  <defunctzombie>they don't need async loading
01:13:33  <defunctzombie>and they don't need a build step
01:13:42  <defunctzombie>what they need to do is stop over complicating shit
01:13:47  <defunctzombie>and make some tools that don't suck
01:15:50  * thl0joined
01:19:03  <defunctzombie>the only think i can think is that people want to continue writing shitty js
01:19:09  <defunctzombie>with no organization or reuse
01:19:18  <defunctzombie>I know that when I made these qr widgets recently
01:19:26  <defunctzombie>they ended up way better when I made them modular
01:19:41  <defunctzombie>and removed any additional jquery dep
01:19:45  <defunctzombie>same with synth events
01:19:48  <defunctzombie>and away
01:19:56  <defunctzombie>the list just goes on and on :)
01:20:01  * thl0quit (Ping timeout: 245 seconds)
01:20:11  <Domenic_>not everyone has graduated from knowing about modules to knowing about packages
01:20:20  <Domenic_>(the fact that people in the node community like to conflate them doesn't help ;))
01:20:40  <Domenic_>i think we can use the fact that node has totally figured out packages to help CommonJS win over AMD in the browser
01:21:08  <Domenic_>as npm >>> AMD-using browser package managers
01:21:08  <substack>Domenic_: it doesn't help that es6 is meddling with their own thing that is inferior to both commonjs and amd
01:21:16  <Domenic_>substack: :-/
01:21:30  <substack>we'll just be stuck with that blunder forever is all
01:21:43  <Domenic_>i think es6 modules on the client will be a nonfactor for many many years
01:21:50  <Domenic_>i.e. until ie10 is dead
01:21:54  <defunctzombie>the es6 thing is gonna become a giant shitshow, mostly because if it passes then we have all sorts of fucked up js with different styles
01:22:00  <defunctzombie>modules will be the least of our problems
01:22:18  <Domenic_>es6 in general is fine. but let's not get into it.
01:22:21  <defunctzombie>the best thing the ES people can do actually is to start removing JS features
01:22:30  <substack>agreed
01:22:33  <defunctzombie>I agree.. best not to go down that road
01:22:38  <defunctzombie>it only leads to anger
01:22:41  <defunctzombie>anger leads to hate
01:22:49  <defunctzombie>hate leads to the dark side
01:23:02  <Domenic_>... which leads to awesome lightning powers?
01:24:32  <defunctzombie>yep
01:27:03  * esterellaquit (Quit: esterella)
01:28:27  <Domenic_>AMEN LOUDBOT!
01:31:20  <defunctzombie>haha
01:31:35  <rvagg>dominictarr, juliangruber, ralphtheninja, Raynos LevelDOWN plugins: https://github.com/rvagg/node-downer-rangedel (i.e. NATIVE code injected into LevelDOWN as an npm install).. not quite working yet cause of npm issues, but close
01:32:35  <dominictarr>oh sweet!
01:32:40  <rvagg>a proper db.rangeDel() function that acts on an iterator, no callbacks until its done: https://github.com/rvagg/node-downer-rangedel/blob/master/src/rangedel.cc#L54-L58
01:40:28  * marcello3djoined
01:41:42  <dominictarr>rvagg: https://github.com/dominictarr/json-logdb
01:41:57  <dominictarr>^ need pluggable leveldown tests!
01:45:34  <rvagg>dominictarr: shouldn't be hard, and they are done in tape so they shouldn't be too scary to pull apart
01:46:18  <ralphtheninja>rvagg: nice!
01:48:18  <ralphtheninja>dnode and mux-demux are my new favorite toys :)
01:49:34  * dominictarrquit (Ping timeout: 245 seconds)
01:52:56  * Domenic_quit (Remote host closed the connection)
02:06:30  <mbalho>ralphtheninja: check out duplex-emitter
02:10:54  * thl0joined
02:11:57  <substack>ralphtheninja: hooray!
02:12:30  <substack>yeah once you can pack streams over mux-demux the value of other streaming libs goes up a huge amount
02:12:49  * mikolalysenkoquit (Ping timeout: 248 seconds)
02:13:00  <mbalho>defunctzombie: i like npm-css
02:13:11  <defunctzombie>:D
02:13:40  <ralphtheninja>mbalho: sweet, can you emit events both ways then?
02:16:03  <ralphtheninja>substack: aye, very nice to pass data back and forth on the same wire
02:17:44  <substack>http://substack.net/images/thinkpad.png
02:18:44  * mikolalysenkojoined
02:19:48  <defunctzombie>substack: is that your computer?
02:20:33  <substack>it's very similar to my current computer but has aspects of my last computer
02:21:48  <ralphtheninja>substack: it needs a blinking LED!
02:24:42  <defunctzombie>substack: I need a small cash register favicon
02:27:17  * dguttmanquit (Quit: dguttman)
02:29:34  <defunctzombie>substack: I can pay you in bitcoins :)
02:30:38  * st_lukequit (Remote host closed the connection)
02:32:26  <mbalho>lol
02:34:30  * mikealquit (Quit: Leaving.)
02:35:26  <defunctzombie>bitcoins are becoming more useful haha
02:35:31  <defunctzombie>you can use them on namecheap now
02:35:38  <defunctzombie>I can buy my domains and ssl certs with them!
02:35:56  <ralphtheninja>nice!
02:36:47  <ralphtheninja>I bought two asic miner chips with bitcoins, but I'm probably going to be ripped off
02:37:33  <defunctzombie>ralphtheninja: who did you buy them from?
02:37:38  <defunctzombie>avalon or bfl?
02:37:55  <ralphtheninja>bfl
02:37:58  <defunctzombie>haha
02:38:02  <defunctzombie>you will never see those
02:38:08  <defunctzombie>:p
02:38:35  <ralphtheninja>probably .. I took a chance :)
02:38:47  <defunctzombie>ralphtheninja: na I kid, they will deliver
02:38:52  <defunctzombie>they just suck at estimating
02:39:18  <defunctzombie>I have met Josh
02:39:32  <defunctzombie>actually have met Yifu too (avalon guy)
02:39:43  <defunctzombie>come to think of it I have met a number of bitcoin people haha
02:40:01  <ralphtheninja>cool
02:40:30  <ralphtheninja>well, even if they deliver the difficulty will probably be so high anyway so the chips are useless by then :)
02:40:46  <defunctzombie>ralphtheninja: never useless
02:40:56  <defunctzombie>if the price keeps going up you will be fine
02:41:26  <defunctzombie>and the price will keep going up
02:41:33  <ralphtheninja>yeah I think so too
02:42:19  <ralphtheninja>I made like 3000 euros the past five days, just by twiddling my thumbs
02:42:39  <ralphtheninja>well I didn't, I was programming :)
02:43:25  <defunctzombie>hahahaha
02:46:00  <ralphtheninja>I wonder what cause the latest boom the past few days
02:46:07  <ralphtheninja>caused*
02:46:23  <ralphtheninja>loads of stuff happening right now
02:47:51  <ralphtheninja>defunctzombie: so you know for sure that bfl can be trusted?
02:48:08  <defunctzombie>ralphtheninja: I mean, I know they are real people
02:48:13  <defunctzombie>actually working on the product
02:48:27  <defunctzombie>with stuff making its way to production
02:48:33  <ralphtheninja>nods, good enough for me :)
02:48:36  <defunctzombie>:)
02:48:45  <defunctzombie>they shared a booth at CES with bitpay
02:49:02  * Dr_Kquit (Quit: Leaving.)
02:49:17  * kenperkinsjoined
02:51:44  <ralphtheninja>aaah you were there .. I have a slight memory of you tweeting about it?
02:52:27  <defunctzombie>I wasn't there
02:52:33  <defunctzombie>but talked to the bitpay guys after
02:52:40  <ralphtheninja>ok
02:52:55  <defunctzombie>one year I will go :)
02:53:10  <substack>defunctzombie: http://substack.net/images/cash_register.png
02:53:18  <defunctzombie>wow
02:53:27  <defunctzombie>substack: favicon...
02:53:34  <defunctzombie>how am I gonna turn that into a favicon :D
02:53:44  <substack>http://substack.net/images/cash_register.svg
02:53:45  <substack>is how
02:53:49  <defunctzombie>hahha
02:53:52  <defunctzombie>amazing!
02:55:06  <substack>0.4 hours labor :p
02:55:16  <substack>according to the irc timestamps
02:55:19  <defunctzombie>how many bitcoin ya want?
02:55:21  <ralphtheninja>lol
02:55:37  <substack>what commands do I execute to make a bitcoin wallet?
02:55:45  <defunctzombie>haha
02:55:50  <ralphtheninja>bitcoind :)
02:55:53  <defunctzombie>substack: I recommend blockchain.info
02:56:18  <defunctzombie>you can go the full bitcoind route.. but that is really annoying
02:56:22  <defunctzombie>and the ui sucks
02:56:40  * esterellajoined
02:56:56  <substack>but so
02:56:58  <substack>what command?
02:57:01  <ralphtheninja>you dont need the ui, just use 'bitcoind', should fit substack perfectly
02:57:22  <substack>doing this
02:57:43  <defunctzombie>haha
02:57:45  <defunctzombie>oh man
02:57:48  <defunctzombie>this should be interesting
02:58:16  <ralphtheninja>substack: which linux are you running?
02:58:18  * jibayquit (Remote host closed the connection)
02:58:20  <substack>ubuntu
02:58:31  <ralphtheninja>apt-get install bitcoind
02:58:47  <substack>reading the man page
02:59:35  <substack>"Be safe from instability caused by fractional reserve banking and central banks."
02:59:40  <substack>hahaha
02:59:51  <substack>that is a terrible reason to use bitcoin
02:59:56  <substack>not even true
03:00:18  <substack>why doesn't it say the real reason: "you can buy drugs with bitcoins"
03:00:34  <substack>also cryptoanarchy
03:00:43  <ralphtheninja>you can buy drugs with dollars too :)
03:00:49  <substack>less convenient
03:01:05  <substack>if I can't buy something over the internet it doesn't exist
03:01:17  <ralphtheninja>very convenient if you are a drug dealer and dont know how to install bitcoind :D
03:01:20  <ralphtheninja>hehe
03:01:56  <substack>so how do I make a bitcoin.conf
03:02:10  <substack>or whatever
03:02:43  <substack>oh it's a wallet.dat I guess
03:02:49  <ralphtheninja>yeah
03:02:57  <ralphtheninja>you shouldn't need to configure it all
03:03:17  <ralphtheninja>the conf file is if you want to configure your bitcoind to talk json-rpc etc
03:03:22  * Domenic_joined
03:05:24  <ralphtheninja>there's also a js project https://github.com/bitcoinjs, the server is written in node
03:05:53  <ralphtheninja>haven't only used that one on the test network, not with real btc
03:06:27  <ralphtheninja>it's going to download the whole blockchain now, into ~/.bitcoin and it will take a while
03:07:46  * Domenic_quit (Ping timeout: 252 seconds)
03:08:49  * tilgoviquit (Ping timeout: 248 seconds)
03:09:03  <substack>ralphtheninja: but so... I installed this thing
03:09:08  <substack>how do I make a wallet.dat
03:09:25  <substack>or is it some bullshit daemonized service that is going to make a bunch of files opaquely on my behalf
03:10:18  <ralphtheninja>yes it's some bullshit daemonized service :)
03:10:32  <substack>lame
03:10:41  <substack>I want to use a good version
03:10:44  <ralphtheninja>the wallet.dat should be in ~/.bitcoin
03:10:45  <ralphtheninja>hehe
03:12:08  <substack>why isn't this like a "type this command to do such..." kind of a thing
03:12:10  <substack>this is stupid
03:12:31  <substack>all this crap about ssl and daemons and whatever is just distracting noise
03:12:48  <substack>there is no reason for any of this to be in a bitcoin lib
03:12:57  <substack>just read stdin and write to stdout
03:14:42  <substack>so I need to run a server locally I guess?
03:14:54  <substack>it's telling me error: couldn't connect to server
03:15:05  <ralphtheninja>'bitcoind -daemon'
03:15:53  <ralphtheninja>I agree, it's not the most optimal system
03:15:58  <substack>ffs it just printed "bitcoin server starting" and fork'd itself into a detached process
03:16:05  <substack>programs should never ever do that ever
03:16:33  <substack>ralphtheninja: -server is the good one it seems
03:16:37  <substack>the non-bullshit one
03:16:50  <substack>it's still pretty bullshit in how the port is completely hidden though
03:17:15  <substack>and how all the data directories are entirely opaque
03:17:36  <substack>shit is way too implicit
03:18:48  <ralphtheninja>true, hard to know what's going on
03:20:11  <ralphtheninja>if you run it with -server you enable the json-rpc, which you might not want to do
03:24:06  <substack>well I broke it
03:24:34  <substack>so what the fuck just happened
03:24:42  <substack>my wifi cut out and then the commands stopped working?
03:24:53  <substack>I need to be completely online just to query the local server?
03:25:07  <substack>some "distributed" software
03:25:13  <ralphtheninja>hehe
03:25:15  <substack>this is complete garbage
03:26:13  <defunctzombie>what you need to do is stop trying to use this bitcoind crap
03:26:20  <defunctzombie>and just go to blockchain.info haha
03:27:23  <defunctzombie>or coinbase if you want to try that
03:27:32  <substack>a central server for wallets would seem to completely miss the point
03:28:09  <ralphtheninja>perhaps we should make something better instead
03:28:21  <substack>making better software is so easy
03:28:24  <substack>you just do less things
03:28:25  <substack>bam
03:28:26  <ralphtheninja>but I have better stuff to do :)
03:28:26  <substack>done
03:30:03  <defunctzombie>substack: blockchain.info doesn't store your keys supposidly
03:30:09  <defunctzombie>they encrypt client side
03:30:13  <substack>partition tolerance is pretty fucking important for a cryptocurrency implementation
03:30:13  <defunctzombie>or some such
03:30:50  <defunctzombie>the point is that you can very easily be in control, but can also trust services to some amount if you wish
03:30:52  <defunctzombie>totally up to you
03:30:59  <substack>all it would take is one xss bug and everybody is fucked
03:32:30  * dguttmanjoined
03:35:09  * tilgovijoined
03:37:42  * marcello3dquit (Remote host closed the connection)
03:38:10  * marcello3djoined
03:38:28  * marcello3dquit (Read error: Connection reset by peer)
03:38:51  * marcello3djoined
03:48:09  * st_lukejoined
03:51:34  <defunctzombie>substack: yep
03:51:39  <defunctzombie>very awesome hahaha
03:53:20  <ralphtheninja>I have this file, it contains 'abcde\n' and I pipe it over mux-demux with createReadStream() .. on the other end I pipe the result to createWriteStream('./foo') .. but the result I get is '[object Object]'
03:53:41  <ralphtheninja>if I add a 'data' listener to the stream I get a huge json blob:
03:53:50  <ralphtheninja>{ '0': 97,
03:53:50  <ralphtheninja> '1': 98,
03:53:50  <ralphtheninja> '2': 99,
03:53:50  <ralphtheninja> '3': 100,
03:53:50  <ralphtheninja> '4': 101,
03:53:52  <ralphtheninja> '5': 10,
03:53:55  <ralphtheninja> length: 6,
03:53:57  <ralphtheninja> parent:
03:54:00  <ralphtheninja> { '0': 97,
03:54:02  <ralphtheninja> '1': 98,
03:54:05  <ralphtheninja> '2': 99,
03:54:13  <ralphtheninja>it continues down to like 40k rows
03:54:52  <ralphtheninja>I can tell it's abcde\n at the beginning there, but I don't know how to serialize it properly to disk
03:55:50  * dguttmanquit (Read error: Connection reset by peer)
03:56:31  <ralphtheninja>insane overhead for just a six bytes file :)
03:56:46  <mbalho>ralphtheninja: its a buffer
03:57:11  <mbalho>nodejs.org/api/buffer.html
04:03:26  <ralphtheninja>mbalho: ✔
04:04:36  <ralphtheninja>mbalho: stream.pipe(fs.createWriteStream('foo')), do I need to pipe stream through something else to get the content from the buffer?
04:04:55  <substack>ralphtheninja: .pipe(through(function (buf) { this.queue(String(buf)) })).pipe(...)
04:04:57  <ralphtheninja>or do I need to listen to the 'data' event and pick out the data myself?
04:07:38  * dguttmanjoined
04:11:29  * thl0quit (Remote host closed the connection)
04:12:11  <ralphtheninja>substack: nopes, still get the [object Object]
04:12:31  * dguttmanquit (Client Quit)
04:13:05  <substack>oh whoops
04:13:19  <substack>try: .pipe(through(function (buf) { this.queue(buf.toString()) })).pipe(...)
04:13:39  * esterellaquit (Quit: esterella)
04:13:42  <substack>actually in my local tests those both do the same thing
04:13:52  <substack>so it might not be plumbed in at the right spot?
04:18:46  * mikolalysenkoquit (Ping timeout: 245 seconds)
04:23:11  <ralphtheninja>substack: https://gist.github.com/ralphtheninja/5105568
04:23:21  <ralphtheninja>tried to cut out some shit and keep the essentials
04:36:17  * juliangruberquit (Quit: No Ping reply in 180 seconds.)
04:36:53  * juliangruberjoined
04:55:24  * wiwilliaquit (Ping timeout: 245 seconds)
05:11:40  * mikealjoined
05:20:25  <py1hon_>substack! jesusabdullah!
05:20:30  * py1hon_changed nick to py1hon
05:20:40  <py1hon>I just signed a lease on a swank new place in the city
05:20:50  <py1hon>walking distance of bart
05:23:32  * mikealquit (Quit: Leaving.)
05:24:50  * tilgoviquit (Remote host closed the connection)
05:25:42  * mikealjoined
05:26:03  * mikolalysenkojoined
05:26:20  <substack>py1hon: sweet!
05:27:20  <substack>I'm near fruitvale bart now
05:30:41  * mikolalysenkoquit (Ping timeout: 256 seconds)
05:32:30  <py1hon>substack: nice, didn't realize you moved! that's quite a bit closer to where i'm at at the moment
05:32:39  <py1hon>(my move in date is april 1st)
05:47:17  * kirbysayshiquit (Quit: Leaving...)
05:48:30  * marcello3dquit (Remote host closed the connection)
05:48:58  * marcello3djoined
05:49:12  <defunctzombie>Raynos: wtf is a reducible?
05:49:27  <Raynos>https://github.com/gozala/reducible
05:49:50  <defunctzombie>Raynos: no
05:49:59  <defunctzombie>that is some custom shit
05:50:05  <defunctzombie>will not have
05:50:08  <Raynos>...
05:50:13  <Raynos>so its only values and elements?
05:50:18  <Raynos>then ill maintain fork forever :D
05:50:20  <defunctzombie>yea
05:50:21  <Raynos>MAINTAIN FOVEREVER
05:50:22  <defunctzombie>https://github.com/Raynos/tryme/commit/58be6fc3f96aff762ce5984056493a559b6ae3ed#L0L7
05:50:25  <defunctzombie>what happened there?
05:50:37  <defunctzombie>was render not being used hahaa?
05:50:43  <Raynos>yeah
05:50:47  <defunctzombie>amazing
05:51:11  <defunctzombie>Raynos: it shouldn't be tied to some special object class you have
05:51:30  <defunctzombie>you should just display that in examples
05:51:36  <defunctzombie>cause that is how people would have to use it
05:51:42  <defunctzombie>not some magic that does it for them
05:51:51  <defunctzombie>or make a module that does something about it
05:52:06  <Raynos>sec
05:52:09  <defunctzombie>if you have that magic, then it will be confusing to see an example that just works
05:52:19  <defunctzombie>but then isn't really valid in a similar use case
05:53:04  <Raynos>its useful for my use-case
05:53:08  <Raynos>ill show you my use-case
05:53:19  * marcello3dquit (Ping timeout: 245 seconds)
05:54:17  * dominictarrjoined
05:57:21  <Raynos>defunctzombie: http://raynos.graphics-server.jit.su/react/mouse-position-image.js
05:57:32  <Raynos>now in my demo you can see both state and view
05:57:34  <Raynos>in real time
05:59:13  <jesusabdullah>sick image brah lol
05:59:22  <jesusabdullah>also sick hosting service brah
05:59:32  <Raynos>:D
05:59:38  <Raynos>jitsu is actually a pain in the ass to host one
05:59:39  <Raynos>on*
05:59:48  <Raynos>had to create a server ( https://github.com/Raynos/graphics-server )
05:59:54  <Raynos>https://github.com/Raynos/graphics-server/blob/master/index.js#L4
05:59:57  <jesusabdullah>and yet here you are? XD
05:59:58  <Raynos>just to trick it to run my command
06:00:13  <Raynos>im on jitsu because I already pay for it and its easy once set up :D
06:00:22  <jesusabdullah>I see
06:00:24  <jesusabdullah>I mean
06:00:36  <jesusabdullah>Zero comment on whether nodejitsu is good or bad or indifferent
06:00:58  <defunctzombie>Raynos: sure, but that is because your applciation state is some magical object
06:01:00  <defunctzombie>and not an element
06:01:07  <defunctzombie>you could have just reduced first
06:01:12  <defunctzombie>and then rendered the element
06:01:25  <defunctzombie>or any number of things to make it work
06:01:25  <Raynos>defunctzombie: that's a pain in the ass
06:01:32  <defunctzombie>Raynos: that is how your users would have to use it
06:01:33  <Raynos>I know what I mean when I say I want to see the value of the thing
06:01:37  <Raynos>for a dom element I want to see an element
06:01:45  <Raynos>for a Stream / Reducible / Signal i want to see the damn value over time
06:01:47  <defunctzombie>your lib is some custom thing you have
06:01:52  <defunctzombie>not a thing browsers have
06:01:57  <Raynos>agreed
06:01:58  <defunctzombie>will not support
06:02:11  <defunctzombie>cause it isn't how an example would really be
06:02:16  <defunctzombie>misleads the users imho
06:02:25  <defunctzombie>cause I can't just add that thing to the dom
06:02:26  <Raynos>how is it misleading?
06:02:33  <Raynos>its misleading
06:02:37  <Raynos>that the result of render
06:02:38  <Raynos>is a dom element
06:02:43  <Raynos>all you care about is
06:03:39  <defunctzombie>Raynos: yes, and you jsut made it handle your random custom object
06:03:45  <defunctzombie>wow
06:04:02  <defunctzombie>Raynos: I do not approve because reducer is some custom object local to your libs
06:04:09  <defunctzombie>nothing else "renders" reducers
06:04:16  <defunctzombie>so just show me how to actually use a reducer
06:04:27  <defunctzombie>and don't hide it behind some other rendering veil
06:05:22  <Raynos>but I dont care about it
06:05:25  <Raynos>the thing is
06:05:27  <Raynos>this is different
06:05:30  <Raynos>your entire app is a stream
06:05:36  <Raynos>you dont do anything with the intermediate values
06:05:48  <Raynos>its just very useful for understanding to see whats flowing through the intermediate variable
06:06:01  <Raynos>do you not see this as a useful thing ignoring the fact that reducers is evil magic
06:06:17  <Raynos>defunctzombie: what about if the thing has a `__render__` method call that?
06:06:25  <defunctzombie>no
06:06:35  <defunctzombie>again, custom things for your framework
06:07:20  <defunctzombie>I think you should show how those would actually be used in js and not hide it
06:07:30  <defunctzombie>looking at your example I would have no clue how to render that myself
06:07:41  <defunctzombie>because reducers are some custom concept
06:08:09  <defunctzombie>if you are annoying with repeating that code to render it in examples, then maybe you need a module or something nicer :)
06:08:17  <defunctzombie>but hiding it in tryme is not the answer
06:15:17  * esterellajoined
06:18:40  <Raynos>defunctzombie: the example SHOWS how you would use it
06:18:46  <Raynos>the only thing you do with the intermediate example
06:18:48  <Raynos>is map it
06:18:49  <Raynos>like below
06:19:00  <Raynos>you dont render the intermediate result
06:19:00  <Raynos>ever.
06:19:08  <Raynos>you just want to see it for learning / understanding
06:19:34  <Raynos>but you have a point
06:19:38  <Raynos>I can create an inspect function
06:19:46  <Raynos>which returns a dom element -.-
06:19:51  <defunctzombie>yes
06:19:57  <Raynos>thats a pain
06:20:05  <Raynos>this is cleaner
06:20:17  <defunctzombie>dominictarr: ping
06:20:23  <defunctzombie>Raynos: to you yes, to everyone else no
06:21:04  <dominictarr>defunctzombie: whats up?
06:21:15  <defunctzombie>question
06:21:22  <defunctzombie>raw data -> split -> jsonstream
06:21:31  <defunctzombie>inside of split I need to emit json data right?
06:22:00  <defunctzombie>however I can't seem to find a way to do that
06:22:16  <defunctzombie>var stream = this; inside the split function isn't the stream
06:22:24  <dominictarr>split('\n', function (raw) { return JSON.parse(raw) })
06:22:28  <defunctzombie>so I can't stream.emit('data',
06:22:31  <defunctzombie>oh, return
06:22:43  <defunctzombie>doesn't split already do newline be default?
06:22:53  <defunctzombie>dominictarr: it isn't json data coming in
06:22:55  <defunctzombie>but I get the point
06:23:02  <dominictarr>you are right
06:23:11  <defunctzombie>thanks :)
06:23:15  <dominictarr>it checks if it's a function
06:30:29  <defunctzombie>dominictarr: https://github.com/shtylman/fpddir
06:30:30  <defunctzombie>rofl
06:30:32  <defunctzombie>quick hack
06:30:33  <defunctzombie>haha
06:31:08  <dominictarr>federal reserve e-payments?
06:31:45  <defunctzombie>routing numbers
06:31:56  <defunctzombie>this is what banks use to send money to other banks
06:32:02  <defunctzombie>sort like "addresses" for a bank
06:32:09  <defunctzombie>within the federal reserve clearing system
06:35:07  * shamaquit (Remote host closed the connection)
06:43:45  * defunctzombiechanged nick to defunctzombie_zz
06:54:37  <Raynos>ugh I need to figure out how to turn a subset of jshint off
07:00:09  * marcello3djoined
07:02:10  * esterellaquit (Quit: esterella)
07:02:32  * marcello3dquit (Read error: Operation timed out)
07:11:43  <rvagg>juliangruber: https://github.com/rvagg/node-upper-rangedel/tree/master/example
07:11:55  <rvagg>you'll have to `npm install` twice to make it work unfortunately
07:12:04  <rvagg>working on that, https://github.com/isaacs/npm/issues/3219
07:12:20  <juliangruber>require('upper-rangedel').use()
07:12:27  <juliangruber>so it must be sth global?
07:12:30  <rvagg>but still! a fully native .rangeDel() with readStream() arg compatibility
07:12:53  <juliangruber>that is sweeeet
07:12:59  <juliangruber>when that works
07:13:04  <juliangruber>so much more will work!
07:13:24  <rvagg>juliangruber: yeah, if you want a different .batch() you can overwrite the .batch() implemented in LevelDOWN
07:13:35  <rvagg>the global stuff happens here: https://github.com/rvagg/node-levelup/blob/pluggability/lib/levelup.js#L55
07:14:00  <rvagg>and in leveldown, here: https://github.com/rvagg/node-leveldown/blob/plugins/src/leveldown.cc#L13
07:14:18  <rvagg>I'm excited cause it's totally mad science but it works
07:14:32  <juliangruber>yeah
07:14:37  <juliangruber>congrats man :)
07:15:05  <rvagg>of course this makes leveldb comparators for different sorting algorithms very simple
07:15:25  <rvagg>just got to think of one to use as an example to show others' how to do it
07:16:25  <juliangruber>it would be cool to have upper and downer in one package
07:18:42  <rvagg>juliangruber: they can be, but I decided to separate them cause you can use downer-rangedel + leveldown alone
07:19:00  <rvagg>so if you're hardcore enough and don't want to use leveldown then you can still have your rangeDel() method
07:20:05  <rvagg>btw, the levelup pluggability stuff I'm playing with has an example here: https://github.com/rvagg/node-levelup/blob/pluggability/externs_example.js
07:20:25  <rvagg>I'll write it up in an issue so it can be critiqued, it's quite different to the level-hooks approach
07:20:32  <dominictarr>rvagg: when using reverse: true, do I have to reverse the order of start, end?
07:20:39  <dominictarr>like, have start > end?
07:20:44  <rvagg>dominictarr: yes
07:20:48  <dominictarr>cool
07:22:12  * st_lukequit (Remote host closed the connection)
07:25:23  <rvagg>Raynos: what on earth are you doing retweeting tweets from 2010?
07:25:38  <Raynos>rvagg: Did I break twitter protocol?
07:25:44  <rvagg>you broke something
07:25:46  <Raynos>:D
07:25:48  <rvagg>how did you even find that?
07:25:51  <Raynos>google
07:25:54  <rvagg>arr
07:25:56  <Raynos>i searched for
07:26:00  <Raynos>"HOW DO I SHUT JSLINT UP"
07:26:03  <Raynos>and I found that
07:26:24  <rvagg>my beef is: JSHint: "__proto__ has been deprecated", me: "WRONG!"
07:26:50  <rvagg>today anyway
07:27:00  <rvagg>tomorrow I'll find some new outrage
07:30:16  <jjjjohnn1y>this chromebook doesnt have a pageup key
07:30:20  <jjjjohnn1y>or pagedown
07:30:29  <jjjjohnn1y>and i am running ubuntu
07:30:45  <jjjjohnn1y>q: how do i get page up and page down
07:31:38  <Raynos>rvagg: you shouldnt use __proto__, especially if your going to mutate it
07:32:03  <Raynos>todays fruits ( http://raynos.graphics-server.jit.su/full/mario.js )
07:46:52  * zero_coderjoined
07:48:32  <zero_coder>heello
07:49:12  <substack>ahoy
07:49:18  <substack>:w
07:53:31  <rvagg>Raynos: I'm a __proto__ lover, use it all the time and neither you nor JSHint can stop me
07:54:12  * zero_coderquit (Ping timeout: 250 seconds)
07:55:53  <substack>rvagg: what for?
07:56:36  * rowbitquit (Ping timeout: 264 seconds)
07:59:55  * rowbitjoined
07:59:58  <substack>there we go
08:00:00  <substack>silly rowbit
08:05:48  <Raynos>rvagg: what do you use __proto__ for
08:07:04  * Domenic_joined
08:11:51  <juliangruber>rvagg dominictarr: I just benchmarked multilevel...even if it's not going over the network performance is at about 4% of the native calls
08:12:14  <juliangruber>I also tried msgpack as the serialiser but that doesn't help
08:12:54  <dominictarr>well, I havn't optimized mux-demux at all
08:13:15  <dominictarr>compare it to just streaming it directly over tcp
08:13:19  * Domenic_quit (Ping timeout: 245 seconds)
08:13:34  <dominictarr>then we'd have a baseline
08:22:15  <juliangruber>dominictarr: https://gist.github.com/juliangruber/5106424
08:23:19  <dominictarr>juliangruber: what about if you just stream that message over tcp?
08:23:23  <substack>starting to document my mad science projects http://browserling.com:9088/mad-science
08:23:38  <dominictarr>is multilevel direct in-process?
08:23:49  <dominictarr>or over the network, but the same machine?
08:24:00  <juliangruber>dominictarr: everything is in the same process
08:24:15  <juliangruber>multilevel direct is just client.pipe(server).pipe(client)
08:24:22  <juliangruber>and network is with tcp in between
08:24:24  <dominictarr>oh!
08:24:29  <dominictarr>that is not good then
08:24:43  <juliangruber>what comes to play here is mux-demux and dnode
08:24:58  <dominictarr>need a flamegraph
08:24:59  <juliangruber>that's essentially all that gets called
08:25:16  <dominictarr>I havn't done any optimizations for mux-demux
08:25:24  <juliangruber>I'll try to get one
08:25:29  <dominictarr>waiting for a usecase where it really matters!
08:25:32  <juliangruber>oh, first I'll check network traffic
08:26:07  <dominictarr>substack: nice!
08:28:03  <juliangruber>traffic is 24x the put payload
08:29:17  <juliangruber>I'll try to get a flamegraph
08:38:07  * st_lukejoined
08:42:42  <juliangruber>meh, mac os doesn't support dtrace ustack helpers
08:43:36  <juliangruber>dominictarr: how do you get flamegraphs?
08:43:52  <dominictarr>it's a d-trace thing
08:44:01  <juliangruber>yes I know that
08:44:08  <juliangruber>but mac os doesn't have the ustack helpers
08:44:21  <dominictarr>hmm, I've never actually tried this stuff...
08:44:25  <dominictarr>smartos?
08:44:28  <juliangruber>:D
08:44:45  <juliangruber>I'll try to get something working somewhere
08:57:10  <rvagg>substack, Raynos; `this.__proto__ = EventEmitter.prototype` used to be in levelup's constructor until the killjoys came along and replaced it with util.inherits()
08:57:44  <Raynos>:D
08:57:58  <rvagg>actually, some of my more fun uses of __proto__ appear to have been replaced by contributors to my OSS projects
08:58:06  <rvagg>obviously lots of people don't think it's as fun as I do!
08:58:23  <rvagg>I'm sure if we had an Object.setPrototypeOf() everyone would be using it, it's the __ that puts people off
08:58:51  <rvagg>I like this kind of thing: https://github.com/TooTallNate/node-bindings/blob/master/bindings.js#L51
08:59:01  <rvagg>.. tho I prefer not to mess with other people's objects
08:59:42  <rvagg>i.e. if someone gives you an object, you shouldn't change it unless your API explicitly gives you permission
09:00:00  <rvagg>but..
09:01:53  <Raynos>rvagg: I think mutating the prototype is a rubyism
09:02:04  <rvagg>ooo, them's fighting words
09:02:05  <Raynos>its like a thing you want to do if you want to make your code magic and unreadable
09:03:04  <rvagg>yeah, well, it's not something you ought to splash around too much, but we ought to embrace JS's prototypal nature rather than shunning it
09:03:57  <Raynos>i prefer to pretend it doesnt exist
09:04:01  <Raynos>unless I need performance
09:04:13  <rvagg>this, for example, is one of the nicest uses of plain object prototypes IMO: https://github.com/isaacs/npm/blob/master/lib/install.js#L911-L926
09:04:18  <rvagg>coupled with Object.create() elsewhere
09:17:46  * ins0mniajoined
09:40:27  <juliangruber>dominictarr: I got flamegraphs :O
09:40:47  <juliangruber>this is just the direct client.pipe(server).pipe(client) doing a lot of puts
09:42:43  <juliangruber>hmm, this is kinda hard to read as I can't tell dnode, mdm and levelup apart
09:43:29  <juliangruber>and only a few lines have actual line numbers with file names
09:46:43  <juliangruber>
09:46:46  <juliangruber>this one is better
09:47:07  * shuaibjoined
09:48:07  <rvagg>I don't see much levelup in there (phew)
09:48:10  * rvaggblames dnode
09:50:21  <juliangruber>something seems to do many many indexOf calls or calls on big arrays
09:50:54  <juliangruber>oh, yeah, since I started 1e6 put calls at the same time dnode must have a lot do handle
09:54:55  * cianomaidinjoined
09:56:17  <juliangruber>I'll write a test that uses a writestream rather than 1e6 puts
09:57:37  * cianomaidinquit (Client Quit)
10:00:00  * cianomaidinjoined
10:04:11  * calvinfoquit (Ping timeout: 245 seconds)
10:09:22  * st_lukequit (Remote host closed the connection)
10:10:49  * st_lukejoined
10:11:27  <juliangruber>rvagg: writestream.on('close', fn) doesn guarantee that everything has been written, right?
10:11:30  <dominictarr>juliangruber: I think I know what that is
10:11:36  <dominictarr>what the indexof is
10:11:51  <juliangruber>dominictarr: in the dnode-protocol?
10:11:58  <dominictarr>year
10:12:00  <dominictarr>yeah
10:12:14  <dominictarr>dnode traverses the arguments and checks for cycles
10:12:42  <dominictarr>but the only way to do that is to with an ===
10:12:55  <dominictarr>because there is no objectId or anything in js
10:13:14  <juliangruber>mhm
10:13:35  <dominictarr>I think you can trust that there are no cycles here
10:13:53  <dominictarr>just use a simpler rpc
10:14:12  <juliangruber>do you know another rpc that has a stream interface?
10:14:17  <dominictarr>https://github.com/dominictarr/rpc-stream
10:14:30  <juliangruber>sweeeeeet
10:14:57  <dominictarr>it assumes that the only cb is the last arg
10:15:04  <dominictarr>and that everything is jsonable
10:15:19  <juliangruber>ok cool
10:15:21  <juliangruber>I'll try that
10:30:35  * nicholasfquit (Read error: Connection reset by peer)
10:30:48  * nicholasfjoined
10:30:57  * st_lukequit (Remote host closed the connection)
10:34:52  * ins0mniaquit (Remote host closed the connection)
10:35:18  * kenperkinsquit (Quit: Computer has gone to sleep.)
10:43:57  * cianomaidinquit (Ping timeout: 276 seconds)
10:44:23  * tilgovijoined
10:53:12  <rvagg>juliangruber: perhaps even roll your own, https://github.com/isaacs/simple-protocol
10:54:23  <rvagg>juliangruber: this is worth looking at too, deoxxa has been working on this recently and replaced dnode with it I believe: https://github.com/deoxxa/pillion
10:57:40  * dominictarrquit (Quit: dominictarr)
10:58:15  * tilgoviquit (Remote host closed the connection)
11:01:21  * cianomaidinjoined
11:01:33  * dominictarrjoined
11:03:40  * shuaibquit (Quit: Textual IRC Client: http://www.textualapp.com/)
11:09:07  <juliangruber>rvagg: I just changed everything to dominictarr's rpc-stream and will see how that behaves
11:16:21  * shuaibjoined
11:31:17  * zero_coderjoined
11:32:05  <zero_coder>??
11:32:09  <zero_coder>sorry , got disconnected last time
11:34:29  <juliangruber>zero_coder: you were in #browserling, right?
11:34:55  <zero_coder>yeah
11:34:58  <zero_coder>why juliangruber??
11:38:01  <juliangruber>zero_coder: becourse I saw your "hello" there :)
11:38:22  <zero_coder>lol :)
11:47:18  <juliangruber>duplexer(stream, stream) == "That pattern where you hide all of stream's methods"
12:07:34  <dominictarr>juliangruber: I've added you to rpc-stream, if you want to improve it, go ahead!
12:07:41  * thl0joined
12:08:44  <juliangruber>dominictarr: look ma, it's way faster now! https://gist.github.com/juliangruber/5107595
12:08:51  <juliangruber>sweet :)
12:09:54  <dominictarr>that is way better!
12:10:16  <dominictarr>what does the flamegraph look like now?
12:15:19  <juliangruber>haven't looked at it yet, travis is failing
12:15:40  <juliangruber>usually net.createServer().listen(randomPort) works
12:15:45  <juliangruber>but not now
12:28:08  * dominictarrquit (Quit: dominictarr)
12:33:27  <juliangruber>as far as I remember substack ran tests on testling-ci that spun up a server also?
13:15:07  * st_lukejoined
13:18:33  * AvianFluquit (Remote host closed the connection)
13:19:47  * cianomaidinquit (Ping timeout: 260 seconds)
13:26:00  * shuaibquit (Quit: Computer has gone to sleep.)
13:26:31  * cianomaidinjoined
13:27:49  * mikolalysenkojoined
13:36:50  * shuaibjoined
13:37:55  * marcello3djoined
13:52:52  * shuaibquit (Quit: Computer has gone to sleep.)
13:54:14  * shuaibjoined
14:00:05  <ralphtheninja>juliangruber: what is the performance test you are making?
14:00:13  * thl0quit (Remote host closed the connection)
14:00:28  <juliangruber>ralphtheninja: multilevel with x puts of a 16byte string
14:00:42  <juliangruber>initially multilevel's performance was at 4% of native levelup
14:00:59  <ralphtheninja>lol
14:01:03  <juliangruber>now its at 20%
14:01:16  <juliangruber>*it's
14:02:02  <juliangruber>so in order for multilevel to be useful in performance critical scenarios I need to finish the sharding module so that you can access many databases in parallel
14:02:06  <ralphtheninja>but hmm, isn't the streams from levelup going throuh mux-demux?
14:02:13  <juliangruber>yes it is
14:02:21  <juliangruber>I already swapped dnode for rpc-stream
14:02:39  <ralphtheninja>I just dont see the time critical part for dnode
14:03:47  <juliangruber>it checks for circular references
14:04:09  * spionjoined
14:05:18  <spion>is there a pure-JS client that implements the webkit remote debugging protocol?
14:06:50  <spion>at least the parts that can be implemented in pure JS
14:07:13  <ralphtheninja>juliangruber: aah because you do it 1000 times, dnode has to send data back and forth for the rpc calls and that adds up
14:07:38  <juliangruber>ralphtheninja: that als
14:07:39  <juliangruber>o
14:17:36  <ralphtheninja>juliangruber: is it because you expose so 'many' methods?
14:17:52  <juliangruber>ralphtheninja: i don't think so
14:18:18  <ralphtheninja>just trying to wrap my head around where the bottleneck is :)
14:18:21  <juliangruber>ralphtheninja:
14:18:36  <juliangruber>that is the flamegraph during 1mrd put operations
14:20:25  <juliangruber>through#drain is quite expensie but it also shouldn't be called here
14:21:35  <ralphtheninja>not sure how to interpret the flame graph
14:21:43  <ralphtheninja>red is bad I guess
14:21:47  * jibayjoined
14:25:49  <ralphtheninja>today is flame graph day, need to improve my skillz :)
14:26:57  * thl0joined
14:29:32  <juliangruber>I don't get that yet too
14:29:38  <juliangruber>here is another one:
14:29:54  <juliangruber>that was while it did 10.000 puts repeatedly
14:30:00  * zero_coderquit (Ping timeout: 245 seconds)
14:30:00  <juliangruber>this one looks way nicer
14:30:41  <ralphtheninja>yup
14:35:40  <juliangruber>btw, the colors don't mean anything
14:35:48  <juliangruber>they're just for looking cool and flamy
14:36:30  <ralphtheninja>lol
14:37:00  <ralphtheninja>I streamed a movie over mux-demux yesterday, it worked very well
14:37:07  <juliangruber>:O
14:37:17  <juliangruber>why did you do that :D
14:37:37  <ralphtheninja>just trying things out
14:39:46  <ralphtheninja>why not? :) too much overhead?
14:40:22  <juliangruber>:D
14:40:29  <juliangruber>I'm just amused by that use case
14:40:37  <ralphtheninja>hehe
14:41:25  <ralphtheninja>still doing it locally though so the performance is probably completely misleading :)
14:41:59  <ralphtheninja>anyway, would you mind putting up your performance test code for multilevel in a gist?
14:42:19  <juliangruber>it's in the repo ;)
14:42:34  <ralphtheninja>doh, should have looked first :)
14:42:39  <juliangruber>and I have a joyentcloud smartos machine for running dtrace
14:43:10  <juliangruber>oh and btw the syntax for multilevel became much easier becourse of the switch from dnode to rpc-stream
14:43:52  <ralphtheninja>ok cool, I'll have a poke around
14:43:58  <juliangruber>cool :)
14:44:16  <ralphtheninja>have to walk the dog first, he is looking at me with a grim face
14:45:03  <juliangruber>have fun
14:46:12  <mikolalysenko>oh great javascript meta programming gurus, I am in need of advice
14:46:35  <mikolalysenko>basically I am trying to come up with a nice api for writing inlined/optimized operations on strided higher dimensional typed arrays
14:46:40  <mikolalysenko>here is what I have so far:
14:46:41  <mikolalysenko>https://github.com/mikolalysenko/cwise
14:46:56  <mikolalysenko>it works ok, but the interface is a bit awkward
14:47:22  <mikolalysenko>if you are only doing component-wise operations, everything works as intended, but the problem comes when you try to do a map/reduce operation
14:48:09  <mikolalysenko>what goes wrong is that if you run the code through a minifier, the names of the variables in the pre/post sections can get changed (if that makes any sense)
14:48:27  <mikolalysenko>so maybe it would be better to use a string instead of a function object for the arguments
14:48:47  <mikolalysenko>but the problem with that is that it can't be minified (which sucks) and that you can't get a line number of syntax errors (also sucks)
14:49:06  <mikolalysenko>so, I am wondering if there is maybe a better way to do this
14:49:37  <mikolalysenko>like how can I have it so that I can put some code above and below the main loop, but still keep variable names consistent across all the functions
14:50:32  <mikolalysenko>also note that the way I am using these functions is not as closures, but really as arguments to a macro which expands them into a big loop...
14:55:00  <mikolalysenko>one possibility might be to use a specially structured function, but there is no gaurantee that a minifier won't overwrite things
14:55:34  <mikolalysenko>the other would be to allocate the pre/body/post sections in their own closure, so the minifier couldn't rip them out
14:55:49  <juliangruber>for me code as strings would never be an option
14:55:59  <juliangruber>which minifier are you using?
14:56:06  <mikolalysenko>it doesn't matter
14:56:09  <mikolalysenko>it could be any minifier
14:56:24  <juliangruber>normally they don't mangle names that aren't save to
14:56:27  <mikolalysenko>basically, I would like this module to work in browsers as well as on node
14:56:37  <mikolalysenko>yeah, but the problem is that the names are local to the scope of the function
14:57:01  <mikolalysenko>what that code does is it basically uses node-falafel and the function(){} + '' hack to get the source of the arguments
14:57:06  <juliangruber>ah I see
14:57:10  <mikolalysenko>then it rips them apart and packages them up in a big for loop
14:57:35  <mikolalysenko>it does this because iterating over strided nd arrays efficiently is a bit complicated, and so to avoid the hassle it is easier to autogenerate the loops
14:57:41  <juliangruber>I'll come up with something...
14:57:47  <mikolalysenko>ok
14:58:00  <mikolalysenko>though the actual generated code is pretty fast
14:58:20  * tmcwjoined
14:58:36  <mikolalysenko>it ends up performing about as well as a hand tuned for loop, and totally mops the floor with numeric.js
14:58:40  <juliangruber>your problem isn't the minifier but javascript itself
14:59:02  <mikolalysenko>hmm... I'm not sure I follow. Can you explain?
14:59:34  <juliangruber>https://gist.github.com/juliangruber/5108599 that would be your ndsum example written without strings, right?
15:00:26  <mikolalysenko>yeah, something like that
15:00:33  <mikolalysenko>though you are missing a comma
15:01:02  * esterellajoined
15:01:51  <juliangruber>why wouldn't the array#reduce syntax work
15:02:00  <mikolalysenko>how does that work?
15:02:16  <mikolalysenko>actually, I know why
15:02:28  <mikolalysenko>because I have other examples that I want to do rather than just reduce
15:02:48  <mikolalysenko>like, find the index of the min element of an array
15:03:01  <juliangruber>...obviously the syntax you have is wrong, relying on ast trickery to get your logic right is always bad
15:03:20  <juliangruber>there should always be a better way
15:03:25  <mikolalysenko>well, I know how I want the code to work internally
15:03:36  <mikolalysenko>I want to basically generate a loop and then inline a function
15:03:53  <mikolalysenko>calling an external closure would be way too slow, I've experimented and it is not an option
15:04:04  <mikolalysenko>and this does work
15:04:37  <juliangruber>https://gist.github.com/juliangruber/5108599#comment-793038
15:05:01  <mikolalysenko>hmm
15:05:15  <mikolalysenko>that might work
15:05:29  <juliangruber>unsing `this` you can have a reference to sum without ast trickery
15:05:41  <mikolalysenko>yeah, I like it
15:06:01  <mikolalysenko>I wonder if referencing this would slow it down though...
15:06:16  <mikolalysenko>let me try an experiment
15:06:31  * shuaibquit (Quit: Textual IRC Client: http://www.textualapp.com/)
15:06:36  <juliangruber>if that is a problem for you then you're using the wrong language ;)
15:07:17  <mikolalysenko>that's a defeatist attitude right there
15:07:25  <mikolalysenko>besides, how else are you going to do stuff in a browser?
15:07:45  <mikolalysenko>a Java applet?
15:08:18  <juliangruber>no
15:08:28  <juliangruber>I thought it needed to happen on the server
15:08:49  <juliangruber>you can use webworkers to do more in parallel, if that is an option
15:08:58  * defunctzombie_zzchanged nick to defunctzombie
15:09:20  <mikolalysenko>true, but you still want to do stuff fast even in a worker
15:09:29  <mikolalysenko>and at any rate, part of my interest in this is also academic
15:09:47  <mikolalysenko>I want to see how quick you can really do linear algebra/scientific computing in javascript
15:10:54  <juliangruber>ok I understand
15:11:50  <mikolalysenko>and not to brag too much, but the preliminary results are actually quite promising
15:12:11  <mikolalysenko>on most of my examples the loop unrolling/inlining code in that example is about 50-100x faster than numeric.js
15:12:26  <mikolalysenko>and that is not a typo
15:13:03  <juliangruber>hm
15:13:13  <mikolalysenko>though one could argue that it involves doing some pretty insane contortions to get that kind of speed, but I think with the right interface/sugar it could be made pretty pactical
15:13:19  <mikolalysenko>s/pactical/ractical
15:13:48  * mikealquit (Quit: Leaving.)
15:14:06  <juliangruber>felixge is also doing quite evil stuff in his node-mysql library to get it fast, like generating functions through strings and evaling them instead of doing loops
15:14:22  <mikolalysenko>yeah, that is basically what this does
15:14:32  <mikolalysenko>except even more crazy stuff goes on under the hood
15:14:50  <mikolalysenko>like depending on the stride of the arguments, it generates an optimal cache oblivious traversal order
15:15:02  <mikolalysenko>so you get maximum memory bandwidth for each loop
15:15:26  <mikolalysenko>for example, if you do something like:
15:15:35  <mikolalysenko>cwise(func(a,b) { a += b })
15:16:28  <st_luke>new stream is actually kinda nice
15:16:33  <st_luke>MONDAY
15:17:21  <mikolalysenko>and if the first array is in FORTRAN order while the second is in C order, it will generate a loop that iterates over them using a modification of Prokop's cache oblivious matrix transpose algorithm
15:17:37  <juliangruber>:O
15:17:42  <juliangruber>now that's where I quit :D
15:17:54  <mikolalysenko>it also works in higher dimensions too
15:18:08  <mikolalysenko>so you can have any number of arguments, with any number of dimensions in any striding/ordering
15:18:15  <juliangruber>what do you use this for?
15:18:25  <mikolalysenko>big volume/image processing applications
15:18:35  <mikolalysenko>like scipy type stuff
15:18:49  <mikolalysenko>for example, go through an image and apply a max filter to each pixel
15:18:59  <mikolalysenko>or mask out a sub volume in a big volume
15:19:09  <juliangruber>ok
15:19:26  <mikolalysenko>you can do some of these things on the gpu, but working in js is more flexible and easier to debug/prototype
15:19:31  <juliangruber>then I'm excited to see what you/others will create using your library :)
15:19:34  <mikolalysenko>and in a few situations it can also be faster too
15:20:03  <mikolalysenko>it could also be used as a foundation for doing linear algebra on dense arrays later on too
15:20:16  * yorickjoined
15:20:46  <mikolalysenko>yeah, I am excited about it
15:21:10  <mikolalysenko>but I want to get the interface right, since picking a crappy api would make building on top of it alter on needlessly painful
15:21:54  * Domenic_joined
15:22:22  <juliangruber>mhm
15:22:44  * esterellaquit (Quit: esterella)
15:22:53  <juliangruber>so after thinking about this I'd definitely go with the `this` solution rather than ast trickery. For more complex functions writing code in strings is not an option
15:23:02  <mikolalysenko>I agree
15:23:16  <juliangruber>or you can do cwise(['sum']).begin(function (sum) { ... }) ...
15:23:24  <mikolalysenko>hmm
15:23:28  <juliangruber>so you define the args you need in the beginning
15:23:30  * Domenic_quit (Remote host closed the connection)
15:23:32  <mikolalysenko>also an option
15:23:39  <mikolalysenko>maybe have a field for shared variables?
15:24:06  <mikolalysenko>so you could write like this:
15:24:33  <mikolalysenko>cwise().args(a,b,c...).shared(x,y,z...).pre().body().post().compile()
15:24:48  <mikolalysenko>though that wouldn't work...
15:25:05  * Domenic_joined
15:25:07  <mikolalysenko>since a minifier could rename the shared variables...
15:25:17  <mikolalysenko>bah, the this solution seems like the best bet
15:26:08  <juliangruber>both have their strong points
15:27:03  <mikolalysenko>ok, running a quick test to see how much slower "this" is vs using a local var
15:27:25  <juliangruber>it surely is slower
15:27:36  <mikolalysenko>yes, but let's see how much
15:27:50  <mikolalysenko>if it is <5%, it is probably still worth it
15:28:09  <juliangruber>but with strings you lose references to variables outside your reduce-thing e.g.
15:28:21  <mikolalysenko>well, that happens anyway...
15:28:48  <mikolalysenko>it is a big hack inside and it basically rewrites your functions into the scope of the loop when it generates the code
15:29:03  <juliangruber>like lambdas
15:29:09  <mikolalysenko>yeah
15:29:26  <mikolalysenko>so doing something like: var x = 1000; cwise(function(a) { a += x })
15:29:28  <mikolalysenko>won't work
15:29:46  <juliangruber>hm yeah I'm not much in the space you're in so I can't really judge if that's something you'd do or not
15:30:39  <juliangruber>you could also make your implementation use asm.js
15:30:50  <juliangruber>then it'll be faster than anything we know
15:31:19  <mikolalysenko>I've looked at it, and it should be possible to do that eventually
15:31:36  <mikolalysenko>but I am going to wait until chome supports asm.js and the spec is finalized before I go after it
15:32:06  <mikolalysenko>basically, if asm.js takes off I'll use it but for now it makes more sense to wait since it may end up actually being slower to use it in v8
15:32:32  <jesusabdullah>INTERESTING THEORY
15:32:42  <jesusabdullah>Me, I'm just way too lazy
15:32:47  * dguttmanjoined
15:34:08  <mikolalysenko>the reason why I think it will be slower is that you have to create one of those custom module blocks for each asm.js function you generate
15:34:32  <mikolalysenko>that means that generating asm.js code is a bit slower, and in v8 it also means you have one extra closure hanging around for each function
15:34:55  <mikolalysenko>whereas if you just generate the code directly you save having to store an extra reference to asm.js wrapper module
15:35:04  <mikolalysenko>(for each generated loop)
15:35:30  <mikolalysenko>also generating code for asm.js is a huge pain in the ass
15:35:55  <mikolalysenko>and it isn't clear how firm that specification is anyway
15:36:25  <mikolalysenko>the way I see it, asm.js was written specifically for emscripten and is basically a formalization of the code that it already generates
15:42:45  <mikolalysenko>ok, results are in:
15:43:32  <ralphtheninja>and the award goes to? :)
15:43:33  <mikolalysenko>doing sum without this on a 128x128x128 array for 10000 iterations takes 35538 ms (+/- 100ms or so)
15:43:46  <mikolalysenko>using this: 147405 ms
15:43:57  <mikolalysenko>so, clearly no this wins
15:44:05  <mikolalysenko>:(
15:44:13  <mikolalysenko>and it isn't even close
15:45:15  <juliangruber>meh
15:45:29  <juliangruber>so perhaps that named arguments thing?
15:45:43  <mikolalysenko>yeah, but the problem is that a minifier can rename them within a subroutine...
15:45:44  <jesusabdullah>mikolalysenko: like i said I'm just waaay too lazy to go through that trouble for, well, questionable gains at best
15:45:58  <jesusabdullah>mikolalysenko: if I'm having that problem I proooobably don't even want to be in javascript land
15:46:11  <juliangruber>he wants it to run in browsers
15:46:35  <mikolalysenko>jesusabdullah: well, I agree that asm.js is questionable but I am ok with doing the extra work. my main issue with it is that it is sketchy how big a deal it actually makes
15:46:36  <ralphtheninja>mikolalysenko: screw the minifying
15:46:48  <ralphtheninja>just for test purposes
15:46:54  <mikolalysenko>it does work for test purposes
15:47:17  <mikolalysenko>but the next step is to get something that works well enough to push out to browsers
15:49:40  <mikolalysenko>I got another idea though...
15:50:00  <mikolalysenko>what if I destructured the "this" object dynamically?
15:50:30  <mikolalysenko>that way you could write the code using the this.* syntax, but it could just replace that with custom variables...
15:50:38  <juliangruber>works!
15:50:44  <mikolalysenko>hahaha
15:50:49  <juliangruber>hm but wait
15:51:10  <juliangruber>perhaps minifiers mangle that again
15:51:23  <mikolalysenko>how?
15:51:42  <mikolalysenko>I mean accesses to this need to keep their names consistent, right?
15:51:44  <juliangruber>if this.foo gets rewritten to this.f everytime it appears it should be a safe optimisation
15:51:56  <juliangruber>ah
15:52:07  <juliangruber>most optimisers don't mangle code that gets exported
15:52:13  <mikolalysenko>right
15:52:14  <juliangruber>maybe that's something to go after
15:52:31  <juliangruber>hm...difficult
15:52:54  <mikolalysenko>I think using this.* should be safe from minifiers hacking things up
15:53:01  <juliangruber>ok
15:53:14  <juliangruber>ah, yes of course
15:53:31  <juliangruber>even if it gets changed, as long as it is changed consistently you don't have a problem
15:53:35  <mikolalysenko>yep
15:53:39  <juliangruber>like you said
15:53:41  <juliangruber>^^
15:53:55  <mikolalysenko>ok, I like this plan
15:55:12  <juliangruber>will you create a nice page with benchmarks that let other libs just look like kindergarten?
15:55:28  <mikolalysenko>yep
15:55:41  <mikolalysenko>and I plan on writing a blog post describing what is going on behind the scenes
15:55:57  <mikolalysenko>I already have this little benchmark:
15:55:58  <juliangruber>sweet
15:55:58  <mikolalysenko>https://github.com/mikolalysenko/ndarray-experiments
15:56:04  <mikolalysenko>but it doesn't name names yet
15:56:24  <mikolalysenko>and it doesn't yet compare the performance of cwise to numeric
15:56:31  <rowbit>/!\ ATTENTION: (default-local) paid account successfully upgraded /!\
15:56:31  <rowbit>/!\ ATTENTION: (default-local) danielribes@... successfully signed up for developer browserling plan ($20). Cash money! /!\
15:56:32  <mikolalysenko>or sylvester/closure/etc.
15:56:56  <mikolalysenko>but the results form these experiments were what inspired me to start writing these modules
15:57:13  <juliangruber>the raw typed array is not an option, bc it doesn't work crossbrowser?
15:57:26  <mikolalysenko>it isn't an option because it is horrible
15:57:34  <mikolalysenko>I mean you can do it, but it is a terrible mess
15:57:46  <juliangruber>k
15:57:48  <mikolalysenko>basically that boils down to doing all the indexing arithmetic yourself
15:57:53  <mikolalysenko>which is what cwise does for you
15:58:08  <mikolalysenko>it basically translates high level component-wise/map reduce operations into typed array access
15:58:20  <mikolalysenko>and also does it in a way that respects striding/cache layout
15:58:32  <mikolalysenko>so you can do things like constant time array transpose/reversal
15:58:56  <mikolalysenko>here is the base library, though still a wip: https://github.com/mikolalysenko/ndarray
15:59:13  <mikolalysenko>I am going to eventually remove the .assign() method and reimplement it using cwise
15:59:30  <mikolalysenko>it will probably end up in here: https://github.com/mikolalysenko/ndarray-ops
15:59:40  * kenperkinsjoined
15:59:46  <mikolalysenko>which is basically a numeric.js work-alike api for those who are familiar with that package
16:01:31  <juliangruber>sounds good
16:02:07  * yorickquit (Remote host closed the connection)
16:05:40  <defunctzombie>Raynos: remove the reducible stuff and I will merge the pull :)
16:06:20  <defunctzombie>also feel free to take out render versus just commenting it out if it isn't uesd
16:08:51  * mikealjoined
16:12:33  * cianomaidinquit (Quit: cianomaidin)
16:15:29  * yorickjoined
16:16:20  * dguttmanquit (Quit: dguttman)
16:18:21  * dguttmanjoined
16:23:23  * thl0quit (Remote host closed the connection)
16:24:10  * thl0joined
16:24:13  * thl0quit (Read error: Connection reset by peer)
16:24:44  * thl0joined
16:25:03  * thl0quit (Read error: Connection reset by peer)
16:25:33  * thl0joined
16:25:55  * thl0quit (Read error: Connection reset by peer)
16:26:50  * thl0joined
16:27:08  * thl0quit (Read error: Connection reset by peer)
16:27:45  * kenperkinsquit (Quit: Computer has gone to sleep.)
16:27:58  * thl0joined
16:39:18  * mikealquit (Quit: Leaving.)
16:50:18  * defunctzombiechanged nick to defunctzombie_zz
16:58:11  * tilgovijoined
17:08:11  * st_lukequit (Remote host closed the connection)
17:08:40  * ins0mniajoined
17:11:55  * st_lukejoined
17:13:41  * AvianFlujoined
17:16:28  * mikealjoined
17:19:28  * thl0quit (Remote host closed the connection)
17:20:18  * thl0joined
17:23:56  * cianomaidinjoined
17:30:29  * thl0quit (Remote host closed the connection)
17:31:26  * thl0joined
17:31:30  * thl0quit (Read error: Connection reset by peer)
17:32:00  * thl0joined
17:32:13  * esterellajoined
17:32:23  * thl0quit (Read error: Connection reset by peer)
17:33:15  * thl0joined
17:33:36  * thl0quit (Read error: Connection reset by peer)
17:34:30  * thl0joined
17:34:51  * thl0quit (Read error: Connection reset by peer)
17:35:21  * thl0joined
17:35:47  * thl0quit (Read error: Connection reset by peer)
17:36:35  * thl0joined
17:36:56  * thl0quit (Read error: Connection reset by peer)
17:37:21  * tmcwquit (Remote host closed the connection)
17:37:44  * spionquit (Ping timeout: 246 seconds)
17:37:50  * thl0joined
17:38:12  * thl0quit (Read error: Connection reset by peer)
17:38:40  * yorick_joined
17:38:40  * yorick_quit (Changing host)
17:38:40  * yorick_joined
17:38:41  * thl0joined
17:39:00  * thl0quit (Read error: Connection reset by peer)
17:39:55  * thl0joined
17:40:20  * thl0quit (Read error: Connection reset by peer)
17:41:10  * thl0joined
17:41:15  * chrisdicojoined
17:41:30  * thl0quit (Read error: Connection reset by peer)
17:42:25  * thl0joined
17:42:47  * thl0quit (Read error: Connection reset by peer)
17:43:40  * thl0joined
17:44:03  * thl0quit (Read error: Connection reset by peer)
17:44:29  * thl0joined
17:44:50  * thl0quit (Read error: Connection reset by peer)
17:45:43  * defunctzombie_zzchanged nick to defunctzombie
17:45:47  * yorickquit (*.net *.split)
17:45:47  * owenbquit (*.net *.split)
17:45:47  * chrisdickinsonquit (*.net *.split)
17:45:47  * hij1nxquit (*.net *.split)
17:46:11  * thl0joined
17:46:31  * thl0quit (Read error: Connection reset by peer)
17:47:00  * thl0joined
17:47:19  * thl0quit (Read error: Connection reset by peer)
17:47:25  * mikolalysenkoquit (Quit: Reconnecting)
17:47:40  * mikolalysenkojoined
17:47:52  * thl0joined
17:48:12  * thl0quit (Read error: Connection reset by peer)
17:48:40  * thl0joined
17:49:03  * Domenic_quit (Remote host closed the connection)
17:49:03  * thl0quit (Read error: Connection reset by peer)
17:49:30  * thl0joined
17:49:51  * thl0quit (Read error: Connection reset by peer)
17:50:20  * thl0joined
17:50:39  * thl0quit (Read error: Connection reset by peer)
17:51:09  * thl0joined
17:51:29  * thl0quit (Read error: Connection reset by peer)
17:52:25  * thl0joined
17:52:44  * thl0quit (Read error: Connection reset by peer)
17:53:40  * thl0joined
17:53:50  * tmcwjoined
17:53:51  * hij1nxjoined
17:54:00  * thl0quit (Read error: Connection reset by peer)
17:54:29  * thl0joined
17:54:50  * thl0quit (Read error: Connection reset by peer)
17:56:35  * thl0joined
17:56:58  * thl0quit (Read error: Connection reset by peer)
17:57:50  * thl0joined
17:58:09  * thl0quit (Read error: Connection reset by peer)
17:58:40  * thl0joined
17:59:00  * thl0quit (Read error: Connection reset by peer)
17:59:29  * thl0joined
17:59:49  * thl0quit (Read error: Connection reset by peer)
18:00:20  * thl0joined
18:00:43  * thl0quit (Read error: Connection reset by peer)
18:01:05  * thl0_joined
18:07:41  * thl0joined
18:08:28  * thl0_quit (Read error: Connection reset by peer)
18:10:02  * tilgoviquit (Remote host closed the connection)
18:12:03  * Domenic_joined
18:16:22  * shuaibjoined
18:17:20  * dguttmanquit (Quit: dguttman)
18:26:01  * _ritchjoined
18:27:23  <defunctzombie>st_luke: https://github.com/bmeck/node-checkout
18:29:19  * defunctzombiechanged nick to defunctzombie_zz
18:29:20  * wiwilliajoined
18:29:52  * spionjoined
18:44:57  <Raynos>defunctzombie: I need to reducible stuff :D
18:47:24  * cianomaidinquit (Quit: cianomaidin)
18:48:39  * kenperkinsjoined
18:48:42  * zero_coderjoined
18:53:06  * dguttmanjoined
18:53:44  * zero_coderquit (Read error: Connection reset by peer)
18:54:54  * shamajoined
19:02:29  * st_lukequit (Remote host closed the connection)
19:17:09  * tanepiperquit (Remote host closed the connection)
19:19:34  * tanepiperjoined
19:22:27  * owenbjoined
19:23:42  * Domenic_quit (Remote host closed the connection)
19:24:31  * shuaibquit (Quit: Computer has gone to sleep.)
19:26:17  * shuaibjoined
19:27:27  * mikolalysenkoquit (Ping timeout: 252 seconds)
19:28:45  * defunctzombie_zzchanged nick to defunctzombie
19:29:08  * Domenic_joined
19:30:13  <defunctzombie>Raynos: take your framework idea into your examples
19:39:26  * mikolalysenkojoined
19:52:55  <Raynos>defunctzombie: I want to be able to define what it means to "render" / "visualize" / "inspect" a value in the REPL
19:53:12  <defunctzombie>I disagree
19:53:33  <defunctzombie>I think you need to put that in the example then or write help functions
19:53:37  <defunctzombie>cause that is what a user would need to do
19:53:50  <defunctzombie>the browser is not going to "render" your reducible
19:53:56  <defunctzombie>nor will you be able to add it to the dom
19:54:52  <Raynos>thats not the point
19:54:54  <Raynos>the point is
19:54:59  <Raynos>that its a REPL
19:55:01  <Raynos>not an example
19:55:11  <Raynos>In my production code
19:55:16  <Raynos>I will never render that reducible
19:55:18  <Raynos>but in the REPL
19:55:24  <Raynos>I want to temporarily inspect the value
19:55:29  <Raynos>to gain insight into the state of the program
19:55:34  <Raynos>for debugging / understanding purposes
19:55:38  <Raynos>not for using or building apps
19:59:53  * esterellaquit (Quit: esterella)
20:01:21  <Raynos>defunctzombie: have you watched the video about the mathematica repl?
20:01:43  <Raynos>defunctzombie: http://www.youtube.com/watch?v=sSQ1dqqINrQ watch that to understand the motivation behind interactivate
20:02:08  <defunctzombie>Raynos: yes, I have
20:02:16  <Raynos>wait
20:02:18  <Raynos>thats the wrong video
20:02:27  <defunctzombie>the motivation behind tryme is to have simple interactive examples
20:02:32  <defunctzombie>not a do everything system
20:02:42  <Raynos>http://vimeo.com/44968627
20:02:51  <Raynos>that is the right video
20:03:02  <defunctzombie>reducibles are a custom module you created to have some specific api
20:03:05  <defunctzombie>or behavior
20:03:07  <Raynos>defunctzombie: what I'm saying is I need a way to hook into tryme's rendering logic
20:03:13  * calvinfojoined
20:03:13  <Raynos>A more concrete example
20:03:34  <defunctzombie>Raynos: and what I am saying is I think that is the wrong approach
20:03:35  <Raynos>https://github.com/Raynos/tryme/commit/418377ffb4395454ea2b562c0d3b5008bbc2252e
20:03:41  <defunctzombie>tryme renders a dom element
20:03:42  <defunctzombie>that is it
20:05:16  <Raynos>The default rendering is stupid. The dom rendering is fine, the non dom should use JSON.stringify for objects
20:05:22  <Raynos>defunctzombie: seperate issue, http://tryme.jit.su/Raynos/graphics/examples/react/mouse-position-image.js
20:05:28  <Raynos>that example is out of date
20:05:57  <defunctzombie>Raynos: I could buy JSON.stringify for objects
20:06:13  <defunctzombie>Raynos: haha that example is great
20:06:29  <defunctzombie>Raynos: I would accept a pull request for stringify on objects
20:06:44  <Raynos>defunctzombie: you should accept a pull request that allows customizing the rendering logic somehow
20:06:45  <defunctzombie>but not something specifically checking for .reducible or whatnot
20:07:00  <defunctzombie>Raynos: I don't see why, if you want to render something custom, just make a function
20:07:06  <defunctzombie>it will be much clearer what is going on
20:07:14  <defunctzombie>versus some behind the scenes magic
20:07:14  <Raynos>ok
20:07:18  <Raynos>I think I understand now
20:07:20  <Raynos>there are two use-cases
20:07:25  <Raynos>personal development and REPL inspection
20:07:31  <Raynos>which is what I use local tryme for
20:07:37  <Raynos>and hosted examples that other people can learn from
20:07:45  <Raynos>my solution is great for former, bad for latter
20:08:49  * esterellajoined
20:09:23  <defunctzombie>Raynos: sure
20:09:28  <defunctzombie>I think examples need to be clear
20:09:32  <defunctzombie>and expose what they do
20:09:41  <Raynos>I think I want to use tryme as a development tool not an example tool :D
20:09:59  <defunctzombie>even for personal dev you should be aware of how the shit is being done and if it too annoying to render reducibles manually then maybe that is the problem :)
20:12:49  <Raynos>but
20:12:55  <Raynos>I never want to RENDER reducibles
20:12:57  <Raynos>in application code
20:13:00  <Raynos>I only want to inspect them
20:13:13  <Raynos>so what I want to do with them is inspect them like a debugger like tool
20:13:41  <Raynos>defunctzombie: I have similar problems with streams and a desire to inspect the values flowing through a stream
20:13:55  <defunctzombie>sure, I get that
20:14:02  <Raynos>the best previous solution I have was https://github.com/Colingo/introspect-reduce
20:14:06  <Raynos>which printed every value to the console
20:14:07  <Raynos>and thats spam
20:14:13  <defunctzombie>then make something that will just output a dom element
20:14:16  <defunctzombie>or table or something
20:14:18  <Raynos>rendering the current state in a isolated visual box is beautiful
20:14:18  <jesusabdullah>Spam is good for you!
20:14:24  <defunctzombie>given a stream or reducible
20:14:28  <jesusabdullah>It's high in the calories a growing boy needs
20:15:20  <Raynos>defunctzombie: so my next objection is i dont want to require a function and wrap the value in a function in the example
20:15:26  <Raynos>maybe it's not a bad compromise
20:15:51  * _ritchquit (Quit: Leaving.)
20:15:59  <defunctzombie>Raynos: my claim is that you should do that
20:16:04  <defunctzombie>because that is how your example works
20:16:06  <defunctzombie>and users will see that
20:16:12  <defunctzombie>and go.. oh hey, I kinda want to do that too
20:16:18  <defunctzombie>and use the same approach and function
20:16:35  <defunctzombie>and it is more flexible
20:16:40  <defunctzombie>cause maybe in a day you change your mind
20:16:43  <defunctzombie>and don't want that
20:16:52  <defunctzombie>or want to have elements display in a line or differently
20:18:10  * shuaibquit (Ping timeout: 240 seconds)
20:18:58  <Raynos>defunctzombie: ok I buy it now :P
20:19:03  <defunctzombie>:p
20:21:17  * shuaibjoined
20:29:21  * dominictarrjoined
20:32:44  * spionquit (Ping timeout: 246 seconds)
20:32:51  * shuaibquit (Ping timeout: 260 seconds)
20:34:50  * shuaibjoined
20:35:56  * chrisdicoquit (Quit: ZNC - http://znc.sourceforge.net)
20:38:18  * chrisdickinsonjoined
20:39:28  * defunctzombiechanged nick to defunctzombie_zz
20:43:14  <substack>dominictarr: you should talk to ea about scuttlebutt and how to survive network partitions http://news.ycombinator.com/item?id=5339852
20:49:51  <dominictarr>substack: what is the problem with simcity?
20:50:15  <substack>dominictarr: it only works when directly connected to EA's servers, which are massively overloaded right now
20:50:26  <dominictarr>oh, right
20:50:27  <substack>even if you only want to play a solo game
20:50:52  <dominictarr>that should be illegal
20:51:11  <dominictarr>(not playing a solo game, having to connect to play)
20:51:42  <dominictarr>SimVoxel!
20:52:11  * cianomaidinjoined
20:53:14  <substack>cianomaidin: pong
20:53:18  <substack>saw you ping me on twitter
20:54:32  <tanepiper>I'd love a browser-based Sim City 2000 clone
20:54:48  <tanepiper>that you *could* play online, but as easily play offline
21:00:50  <dominictarr>tanepiper: did you ever play simcopter?
21:01:01  <tanepiper>not really
21:03:09  <guybrush_>dominictarr: thats like saying, it should be illegal to having to connect to the internet to use the internet
21:03:50  <guybrush_>i mean there are games that are just multiplayer-games
21:04:58  <tanepiper>guybrush_: yea, but Sim City has never been a multiplayer game, and now EA are basically forcing it
21:05:08  <dominictarr>well, I meant "should be illegal" like it's a "crime against humanity"
21:05:16  <tanepiper>For example you can't play it on a long flight
21:05:17  <guybrush_>haha :p
21:05:26  * esterellaquit (Quit: esterella)
21:05:32  <tanepiper>Obviously something like Eve Online or WoW is different, that's the model of the game
21:05:38  <guybrush_>tanepiper: it might not fit into their model for making money
21:05:39  <dominictarr>we need to make the internet work offline too!
21:06:05  <tanepiper>guybrush_: then there model is wrong because it makes their customers very unhappy
21:06:24  <guybrush_>i think you are right
21:06:28  * esterellajoined
21:06:40  * Domenic_quit (Remote host closed the connection)
21:13:46  <tanepiper>haha http://www.amazon.com/gp/product/B007VTVRFA?ie=UTF8&force-full-site=1&ref_=aw_bottom_links
21:15:34  * cianomaidinquit (Quit: cianomaidin)
21:17:47  * defunctzombie_zzchanged nick to defunctzombie
21:28:43  * shuaibquit (Quit: Textual IRC Client: http://www.textualapp.com/)
21:30:33  * cianomaidinjoined
21:34:48  * cianomaidinquit (Client Quit)
21:37:02  * Domenic_joined
21:38:41  * cianomaidinjoined
21:45:20  * Domenic_quit (Ping timeout: 255 seconds)
21:46:45  <mbalho>defunctzombie: have you written anything to inline base64 encoded image urls with npm-css?
21:47:04  <defunctzombie>mbalho: nope, generally I would do that at the app level and not at the widget level
21:47:20  <defunctzombie>since the serving of static assets can be app specific
21:47:54  <mbalho>defunctzombie: i was thinking var css = npmcss(/path/to/file, { inlineImages: true }); or something
21:48:13  <defunctzombie>mbalho: could be reasonable
21:48:32  <mbalho>defunctzombie: im just imagining putting something like twitter bootstrap's CSS on npm
21:48:34  <defunctzombie>need to be careful of image sizes and such
21:48:38  <mbalho>defunctzombie: yea of course
21:48:46  <defunctzombie>mbalho: yea, so I do some of that
21:48:52  <defunctzombie>what I favor is allowing the app to handle that
21:48:58  <defunctzombie>and let the widgets do minimal styling
21:49:10  <defunctzombie>and specify the rules to override themselves in a sensible manner
21:50:04  <mbalho>defunctzombie: another thing i was thinking is a spriting framework
21:50:15  <mbalho>defunctzombie: framework is probably a poor choice of words
21:50:28  <mbalho>defunctzombie: but modules would export their sprite and you would merge all sprites into a production sprite
21:50:48  <mbalho>defunctzombie: and rewrite the combined css sprite offsets accordingly
21:51:28  <defunctzombie>mbalho: yea, you can do that
21:51:37  <defunctzombie>mbalho: my approach is generally another field in package.json
21:51:42  <defunctzombie>and make a tool to read that
21:53:41  * cianomaidinquit (Quit: cianomaidin)
21:53:45  <defunctzombie>mbalho: the resolve module actually have a way to hook into package filtering
21:54:04  <defunctzombie>mbalho: which makes it really useful for tools that need to do custom lookups from package.json files
21:54:05  <mbalho>defunctzombie: ive implemented that before
21:54:22  <mbalho>https://github.com/maxogden/lunny/blob/master/lib/lunny.js
21:54:37  <mbalho>defunctzombie: not using resolve though, is it just npm install resolve?
21:54:44  <chrisdickinson>mbalho: ooo, idea
21:54:46  <mbalho>defunctzombie: or do you mean require.resolve
21:54:49  <defunctzombie>mbalho: yea
21:54:53  <defunctzombie>mbalho: npm isntall resolve
21:54:57  <defunctzombie>mbalho: substacks thing
21:54:59  <chrisdickinson>so i'm working on something called resources
21:55:00  <defunctzombie>mbalho: we use it all over
21:55:10  <defunctzombie>mbalho: npm-css, browser-require, module-deps, etc
21:55:22  <mbalho>defunctzombie: gotcha
21:55:27  <chrisdickinson>that you say `resources.provides('/path/to/tar-file')`; `resources.require('path/to/style.css')`
21:55:43  <mbalho>chrisdickinson: cool!
21:55:44  <chrisdickinson>and it would create object urls for `requires`
21:55:53  * spionjoined
21:56:14  <chrisdickinson>so you could write a css parser that transforms `url()` bits into object urls as they become available
21:56:24  <mbalho>chrisdickinson: is object url === data uri?
21:56:27  <chrisdickinson>nope
21:56:32  <chrisdickinson>object url is like a uuid
21:56:39  <mbalho>chrisdickinson: also this is a python module but it is really well maintained + implemented https://github.com/jorgebastida/glue
21:56:43  <chrisdickinson>you register a blob of binary data with a mimetype as an object url
21:56:56  <chrisdickinson>so you're not inserting tons of base64'd data all over the place
21:56:59  * mikolalysenkoquit (Ping timeout: 256 seconds)
21:57:11  <mbalho>chrisdickinson: oh i didnt know you could do that in stylesheets
21:57:23  <mbalho>chrisdickinson: ive interacted with object urls in webrtc i sall
21:57:50  <guybrush_>the docs/api/stream are already up2date right? for 0.10 - really want to dig into streams2 now (cc isaacs)
21:58:16  <mbalho>guybrush_: hey is your game almost out?
21:58:53  <chrisdickinson>mbalho: http://cl.ly/image/3y3K1P0v3z19/cssblob.png
21:58:55  <guybrush_>mbalho: lol we wanted to attend on the mozgame-thing but didnt quite make it :/ (huge fps-drops after some time due phys-problems)
21:59:19  <guybrush_>and now we got some other things running too, really not sure how long it takes lol :p
21:59:26  <mbalho>guybrush_: ahh bummer
21:59:39  <chrisdickinson>but you could also do the pngs as object urls -- just refer to them relative to the path in the tar file, then require them as the css comes through the tar-parse stream
21:59:48  <chrisdickinson>and replace out the url's with object urls
21:59:56  <guybrush_>if we dont get anywhere we will just put it on gh anyway i think
22:00:01  <chrisdickinson>could either be neat or reliably crash your browser
22:00:07  <chrisdickinson>either way it's a feature
22:00:08  * Domenic_joined
22:00:33  <chrisdickinson>mbalho: also, have you seen xhr.responseType = 'moz-chunked-arraybuffer' ?
22:00:44  <mbalho>chrisdickinson: havent played with it
22:00:47  <chrisdickinson>it actually makes streaming binary data from the server via xhr possible
22:01:08  <mbalho>chrisdickinson: chrome wont implement that cause of https://dvcs.w3.org/hg/streams-api/raw-file/tip/Overview.htm
22:01:10  <chrisdickinson>which is nice, because responseType = 'arraybuffer' waits until the entire response is loaded to give you a .response attr
22:01:14  <guybrush_>you can even fetch binary in the webworker!
22:01:19  <chrisdickinson>nyergh
22:01:21  <guybrush_>super sexy thing
22:01:45  <Raynos>defunctzombie: whats your opinion on multiple file examples?
22:01:48  <mbalho>chrisdickinson: yea xhr sucks at streaming
22:01:59  <defunctzombie>Raynos: in what sense?
22:02:17  <Raynos>as in I have an example thats complex
22:02:22  <Raynos>and I want to split in into two files
22:02:25  * tilgovijoined
22:02:27  <Raynos>and I want to be able to have some kind tabbed view
22:02:32  <Raynos>where I can edit both files
22:02:41  <Raynos>maybe a split pane view
22:02:50  <substack>defunctzombie: I think it's better for these css helpery things to just take a string of contents
22:03:15  <substack>oh actually I see what you mean with the url() stuff
22:03:26  <substack>that kind of thing would be good for a browserify transform
22:03:56  <defunctzombie>Raynos: hm, not sure about that one, maybe if you have a folder with no index it can have a tabbed view?
22:04:13  <Raynos>well my desire is actually a local dev desire
22:04:14  <chrisdickinson>substack: the url() stuff i was talking about with object urls, or did i miss something?
22:04:17  <Raynos>which is there is an example
22:04:23  <defunctzombie>Raynos: I tend to favor single file examples hm
22:04:25  <Raynos>and there is the code (../index.js) for the example
22:04:27  <substack>in css files
22:04:35  <Raynos>i want to edit both in the browser
22:04:38  <defunctzombie>ah
22:04:50  <Raynos>there is also larger multiple file examples
22:04:51  <mbalho>chrisdickinson: dunno if you are a sprite fan but when i was doing mobile stuff it was basically the only way to have maintainable images in stylesheets because of all the different screen densities you have to support
22:04:53  <chrisdickinson>my suggestion was that you would transform out url()s and replace them with object urls
22:05:16  <Raynos>defunctzombie: basically I want to do all my development in tryme :P
22:05:27  <chrisdickinson>mbalho: i'm hoping sprites die a swift death due to svg :)
22:05:27  <defunctzombie>Raynos: haha
22:05:35  <mbalho>chrisdickinson: so you would just have an object url that was a single style declaration with base64 inlined inside? or is there a better way to go
22:05:40  <Raynos>and I shall bastardize it until it can do it
22:05:54  <mbalho>chrisdickinson: they are both valid approaches, vector will always take longer to create but will look better
22:06:24  <chrisdickinson>mbalho: i would take the css file, parse out the `urls`, find the images inside a tar file (or otherwise accessible url); download them, turn them into object urls, and shove them back into the css
22:06:56  <chrisdickinson>the downside of object urls is that you have to do this on the client
22:07:01  <chrisdickinson>which kind of sucks
22:07:09  <mbalho>chrisdickinson: in your example screenshot instead of background: red what would it look like syntactically
22:07:12  <mbalho>chrisdickinson: for image data
22:07:31  <Raynos>https://npmjs.org/package/xtend
22:07:32  <Raynos>wait what
22:07:34  <Raynos>people use my stuff?
22:07:34  <chrisdickinson>background: url('path/to/image.png')
22:07:53  <mbalho>chrisdickinson: except the url string would be the object url?
22:07:58  <chrisdickinson>which you would parse and turn into `background: url('blob:urlrurl')`
22:08:23  <chrisdickinson>nope, the css as it comes down would have the original reference, you would parse it and turn it into an object url before handing back the css
22:08:58  <mbalho>chrisdickinson: ok so you make object urls for each image + the entire stylesheet also
22:09:03  <chrisdickinson>yep
22:09:20  <chrisdickinson>you could skip the css object url thing by just making a <style> tag with textContent = the new css
22:09:29  <chrisdickinson>but for each image, yes, object urls
22:09:31  <mbalho>yea
22:10:04  <dominictarr>substack: Raynos http://www.terminally-incoherent.com/blog/2013/03/06/my-wizards-are-different/
22:11:36  <Raynos>https://github.com/Raynos/xtend/issues/8
22:11:40  <Raynos>PEOPLE Y U NO GET SEMVER
22:11:53  <mbalho>chrisdickinson: can blobs be initialized from an array buffer data view? cause then you could send 1 sprite down to the client and then make data views for each image in the image and not have to duplicate memory when parsing the image
22:11:57  <mbalho>chrisdickinson: and also only have 1 request
22:12:13  <chrisdickinson>mbalho: right
22:12:22  <chrisdickinson>yeah, you'd be creating the object urls for each required image once
22:12:33  <defunctzombie>Raynos: now you know what I say to always pin :)
22:12:40  <defunctzombie>Raynos: people are dumb and don't understand dependencies
22:12:41  <chrisdickinson>and blobs can be initialized with typed arrays or buffers
22:12:42  <Raynos>I bumped the major version!
22:12:45  <defunctzombie>so instead of explaining semver
22:12:48  <defunctzombie>I just say pin
22:12:58  <Raynos>dont pin. Use `~x.y` or `~x.y.z`
22:13:24  <Raynos>I think npm's default is great
22:13:31  <Raynos>`~x.y.z` is exactly what I want
22:13:40  <defunctzombie>Raynos: until it isn't :D
22:13:47  <Raynos>I just accept
22:13:50  <Raynos>that I want all new patches
22:13:56  <defunctzombie>Raynos: so for tryme, I don't have an answer for the multi file thing
22:13:56  <Raynos>and if a patch breaks things
22:13:59  <Raynos>then ill just pin
22:14:03  <defunctzombie>as my focus has been on examples currently
22:14:13  <Raynos>defunctzombie: i may hack in some kind of thing :3
22:14:20  <defunctzombie>cool
22:14:33  <defunctzombie>also, local mode can be different in some ways
22:14:37  <defunctzombie>to help a person develop examples
22:14:42  <mbalho>chrisdickinson: ah cool so i think it has a cross browser fallback built in by default...
22:14:51  <Raynos>it already is with the --live flag
22:14:59  <Raynos>the next thing is performance optimization
22:15:01  <mbalho>chrisdickinson: if you have a stylesheet with .foo { background: url('foo.png') }
22:15:03  <Raynos>it takes like 3 seconds to load the page
22:15:08  <mbalho>chrisdickinson: then dumb browsers can just load foo.png
22:15:11  <Raynos>that needs to be hand optimized to be faster for local
22:15:20  * chrisdickinsonnods
22:15:32  <mbalho>chrisdickinson: but if you are in a smart browser your css will be transformed first, which then generates a single request to the server for the composite sprite
22:15:51  <chrisdickinson>yep, or it doesn't have to be a sprite at all -- just a tarball of images
22:16:05  <mbalho>chrisdickinson: same thing :P
22:16:18  <chrisdickinson>well, you don't have to combine all of the images into a single one :)
22:16:24  <mbalho>chrisdickinson: png has zlib in it anyway
22:16:28  <mbalho>chrisdickinson: close enough
22:16:31  <chrisdickinson>yeah
22:16:32  <mbalho>chrisdickinson: :D
22:16:36  <chrisdickinson>tar doesn't compress :)
22:16:46  <mbalho>chrisdickinson: ok ok you win
22:16:48  <chrisdickinson>but you might be able to get some gains from gzipping the tarball
22:16:59  <chrisdickinson>like, if you've got multiple images with similar data, maybe?
22:17:01  <chrisdickinson>i'd have to experiment
22:17:13  <mbalho>chrisdickinson: and the bonus to this approach over spriting is the API is simpler since you just use background: url()
22:17:29  <chrisdickinson>but yeah i have to write this `resources` module
22:17:35  <mbalho>chrisdickinson: whereas with sprites you end up with this https://github.com/maxogden/ViewKit/blob/master/build/sprite.css
22:17:41  <chrisdickinson>it's mostly for voxel-engine / game-core
22:17:47  <Raynos>I'm thinking we should write fpm
22:17:49  <Raynos>which is like npm
22:17:51  <mbalho>chrisdickinson: (that is python glue output)
22:18:04  <Raynos>except you can `fpm build` and it turns node_modules into a single js file that exports a global require
22:18:14  <Raynos>then we can onboard frontend people onto npm + commonJS
22:18:38  <mbalho>Raynos: thats what browserify -r modulename does, right?
22:18:55  <Raynos>yeah
22:19:04  <Raynos>I just think we should have a single easy to install tool called `fpm`
22:19:13  <Raynos>and do some branding / documentation around it
22:19:20  <mbalho>"fucking package managers"
22:19:36  <mbalho>"client side people: use fucking package managers"
22:20:38  <Raynos>I think this is easier then telling people to install npm & browserify
22:21:11  <Raynos>"oh you just run fpm build to create my modules file. cool. I'll drop it in as a script tag next to my jqueriees"
22:22:34  <dominictarr>Raynos: there is something that makes me feel uneasy about the acronym FPM
22:22:56  <Raynos>we can bully isaacs into adding `npm build` for the greater good of onboarding front end people
22:22:59  <Raynos>that would work too
22:24:21  <dominictarr>npm build would be good
22:25:52  <Raynos>i just suspect isaacs will say no
22:25:55  <Raynos>to every feature request
22:25:56  <Raynos>until he dies
22:26:59  <substack>just do `npm run build`
22:27:10  <substack>also
22:27:20  <substack>the biggest complaint npm haters have is discoverability
22:27:29  <substack>just fix that problem with a curated list of npm packages
22:28:29  <chrisdickinson>yeah, there's really not a great solution for discoverability outside of better search and more community blogs
22:29:26  <chrisdickinson>really i want `npm find` that just spurts out configurable lines of metadata
22:29:38  <jesusabdullah>npm search | grep
22:29:40  <jesusabdullah>is how I roll
22:29:47  <chrisdickinson>npm find --author --keywords | grep streams
22:29:55  <jesusabdullah>also hit the couch "by-hand"
22:30:02  <jesusabdullah>if need be
22:30:14  <chrisdickinson>i was experimenting with just using the npm cache
22:30:20  * nicholasfquit (Read error: Connection reset by peer)
22:30:40  <chrisdickinson>also experimenting with just daemonizing something and storing cache data in sqlite or redis or riak for searching
22:30:41  <mbalho>$ time npm search voxel
22:30:42  <mbalho>real0m9.992s
22:30:50  * nicholasfjoined
22:31:04  <chrisdickinson>mbalho: for a canned example of why search is inadequate, `npm search tar`
22:31:26  <mbalho>ahh yea
22:32:12  <Raynos>substack: like https://gist.github.com/Raynos/4350728
22:32:25  <chrisdickinson>also, correct me if i'm wrong, but npm search is just grabbing the changes since N, applying them to the cache json, then loading that entire file and filtering the contents
22:32:29  <Raynos>substack: the aim of npm build is for people that write front end apps
22:32:41  <Raynos>I guess they need a package.json
22:32:50  <jesusabdullah>chrisdickinson: yes
22:33:00  <Raynos>isaacs, dominictarr: what about adding `build` to npm init that uses browserify to create <script> with require global ?
22:33:05  <jesusabdullah>Raynos: back in MY day we used gnu make!
22:33:13  <jesusabdullah>AND THAT WAS GOOD ENOUGH
22:33:36  <jesusabdullah>you just don't understand me LOUDBOT you're never gonna get it
22:33:44  <dominictarr>Raynos: npm build should just run the scripts { build: … }
22:33:48  <dominictarr>in the package.json
22:34:00  <dominictarr>npm run build does that
22:34:00  <Domenic_>yeah maybe we should just evangelize "build": "browserify index.js"
22:34:10  * tilgoviquit (Ping timeout: 240 seconds)
22:34:19  <dominictarr>that is what I do
22:34:35  <Domenic_>btw where are my source maps
22:34:38  <rvagg>meanwhile I'll evangelize "build":"ender ."
22:34:43  <Domenic_>can't do no evangelism if we're still <<< requirejs
22:34:53  <Domenic_>rvagg: not sure if serious -_-
22:35:05  * rvaggserious
22:35:17  <Raynos>Domenic_: they are done
22:35:32  <Raynos>Domenic_: https://github.com/thlorenz/inline-source-map
22:35:47  <Raynos>Domenic_: https://github.com/thlorenz/browserify-sourcemap-poc
22:35:58  <Domenic_>Raynos: yeah but we need browser-pack to get patched IIRC
22:36:11  <Raynos>Domenic_, dominictarr: I want a really easy way for front end people to use npm modules from script tags
22:36:47  <Domenic_>Raynos: understandable. in which case, "build": "browserify index.js -o browserified.js".
22:36:56  <Raynos>and -r flag
22:37:03  <Raynos>and not browserify index.js
22:37:03  <Domenic_>The instructions become "npm install mything. npm run build. <script src="browserified.js">
22:37:11  <Raynos>its not about "write your code in index.js using commonJS"
22:37:26  <rvagg>juliangruber: you around?
22:37:28  <Raynos>its about "npm install by and run npm build. Then include the script tag and have `var by = window.require("by")`
22:37:52  <Domenic_>oh you want npm build on the parent project
22:37:56  <Raynos>i.e. your app code doesnt need to be commonJS and can be global soup
22:38:11  <Domenic_>i was thinking the dependencies include builds and the consumer runs npm build
22:38:16  <Raynos>but you can use `window.require` to load dependencies from npm instead of dropping jquery files into your lib folder
22:38:27  <Domenic_>or, of course, postinstall hooks, but then isaacs will hate us.
22:38:37  <Raynos>no
22:38:40  <Raynos>that's silly
22:38:45  <Domenic_>yeah prepublish is fine
22:38:53  <Domenic_>so you just publish your node modules with a browserified.js in the root
22:38:54  <Raynos>I want `npm build` to turn your local ./node_modules folder into a single file that exports a require global
22:39:01  <Domenic_>hmmmmmmmmmm
22:39:07  <Domenic_>(thank you for explaining.)
22:39:23  <Raynos>so module authors need to do no work
22:39:35  <mbalho>how abotu browserify.org/request returns the output of browserify -r request
22:39:38  <Domenic_>What about if that command was named "browserify"
22:39:57  <Domenic_>e.g. npm install x; npm install y; browserify; good to go.
22:40:04  <Raynos>oh interesting
22:40:08  <Raynos>that could be useful
22:40:23  <Raynos>mbalho: that could work as well actually
22:40:25  <Raynos>just have a server
22:40:45  <mbalho>step 1: use the command line = scary for lots of people
22:40:45  <Raynos>`browserify.org/request/by/class-list`
22:40:56  <defunctzombie>I have been meaning to make a browserify patch to allow for single export
22:40:57  <Raynos>I think that's actually a way better idea
22:41:00  <defunctzombie>for non browserify users
22:41:16  <defunctzombie>but people using browserify on node.js should just use a lib that does this shit automatically
22:41:17  <Raynos>and that file when requested will export a global require
22:41:25  <Raynos>no installing npm, node or browserify
22:41:26  <defunctzombie>manual build steps are stupid
22:41:44  <defunctzombie>Raynos: sure, you just publish a dist.js with your project on github
22:41:48  <defunctzombie>like people do now
22:41:58  <Raynos>no
22:42:01  <Raynos>I dont want to do that
22:42:03  <Raynos>that's stupid
22:42:10  <Raynos>I dont want to make module authoring any harder
22:42:20  <Raynos>I want to make loading commonJS modules outside of a commonJS environment trivial
22:42:59  <jesusabdullah>I'll evangelize gnu make!
22:43:05  <jesusabdullah>(and I'LL form the HEAD!)
22:43:19  <thl0>Raynos: sourcemaps are almost there
22:43:56  <thl0>I created a separate module for it and have a browser-pack fork that uses it https://github.com/thlorenz/browser-pack/tree/inline
22:44:01  <substack>thl0: will the new sourcemap support avoid the eval()/Function() hacks we had to do before?
22:44:08  <thl0>substack: yes
22:44:11  <substack>excellent
22:44:36  <thl0>substack: I want to add some tests to my browser-pack change and will submit another PR
22:45:09  <Raynos>substack: What do you think of `browserify.org/npm/request` returns `browserify -r request` ?
22:45:32  <Raynos>that way we can tell front end people just `<script src=browserify.org/npm/request>` and no installing node or CLI tools
22:45:40  <Domenic_>so good
22:45:47  <Raynos>the main question is, is it cool to host it on browserify.org ?
22:45:51  <substack>Raynos: sounds great but I don't really have the server power/disk for that right now
22:45:59  <defunctzombie>Raynos: yea
22:46:03  <defunctzombie>Raynos: and the way you do that
22:46:10  <defunctzombie>is by having a .js that those people can use
22:46:13  <defunctzombie>right on github
22:46:15  <defunctzombie>substack: https://github.com/substack/insert-module-globals/blob/master/package.json#L13
22:46:16  <thl0>substack, Raynos: then I'll create a browserify fork which uses that pack fork and adds a commandline arg to turn on sourcemaps
22:46:17  <Raynos>substack: ok just DNS forward it to me or someone else
22:46:19  <Raynos>ill host it
22:46:27  <defunctzombie>substack: this depends on a very old module deps
22:46:33  <defunctzombie>substack: why does it even need module deps?
22:46:44  <substack>doesn't anymore
22:46:46  <defunctzombie>substack: given that browserify and this use module-deps the two get out of sync
22:46:55  <thl0>substack: I'll want to have it working end to end before I submit the PRs
22:47:09  <Domenic_>have we got `Buffer` detection working yet
22:47:10  <substack>thl0: sounds good
22:47:17  <thl0>cool
22:47:19  <jesusabdullah>YOU're Buffer detection!
22:47:43  <defunctzombie>substack: should that dep be removed then?
22:47:49  <chrisdickinson>Domenic_: not since last i checked (a week ago, probably?)
22:48:11  <chrisdickinson>also, the lack of array indexing on buffer-browserify buffers drives me crazy ):
22:48:28  <jesusabdullah>is that fixable?
22:48:37  <chrisdickinson>make them typed arrays
22:48:41  <jesusabdullah>getters/setters ?
22:48:43  <jesusabdullah>:v
22:48:51  <jesusabdullah>also I don't remember how typed arrays work :(
22:48:56  <substack>chrisdickinson: send toots a pull req on buffer-browserify
22:48:59  <chrisdickinson>you would have to do it in a loop, but yeah, that would work too
22:49:09  <mbalho>90% of the time you can s/Buffer/Uint8Array and code works
22:49:13  <chrisdickinson>substack: what's the stance on things like buffer-browserify depending on other packages?
22:49:42  <substack>chrisdickinson: it makes insert-module-globals MUCH more complicated when you have dependencies
22:49:48  <chrisdickinson>ah, damn
22:50:10  <chrisdickinson>i'll need to copypasta http://npm.im/to-utf8, since buffer-browserify's toString('utf8') is a bit busted
22:50:40  <substack>chrisdickinson: write a script to concat them together
22:50:52  <jesusabdullah>sounds gnar
22:51:04  <chrisdickinson>substack: as part of "prepublish" on buffer-browserify?
22:51:16  <substack>however
22:51:35  <substack>defunctzombie: fixed in 0.1.3
22:51:42  <defunctzombie>substack: \o/
22:52:06  <substack>chrisdickinson: also please add tests to make sure everything works down to at least ie8, preferrably ie6
22:52:15  <substack>if you go down the fixing buffer-browserify route
22:52:18  <defunctzombie>I love how fast we fix shit around here
22:52:26  <substack>then testling core can depend on it
22:52:49  * dominictarrquit (Quit: dominictarr)
22:52:51  <chrisdickinson>substack: yeah, that's the issue with typed arrays. maybe it should just fallback to a plain array if no typed array is available
22:53:02  <substack>sure
22:53:36  <chrisdickinson>what's the mechanism for swapping some module of your own for one of the builtins in browserify?
22:53:51  <chrisdickinson>or is there one?
22:54:01  <substack>chrisdickinson: https://github.com/substack/node-browserify/pull/290#issuecomment-14005841
22:55:38  <mbalho>hey if i got a grant to work on a 'github for structured data' project would anyone wanna contract?
22:56:49  <mbalho>(basically an excuse to write an app using leveldb + node)
22:57:04  * tilgovijoined
22:57:10  <defunctzombie>mbalho: is this that startupbus startup?
22:57:18  <mbalho>defunctzombie: haha no
22:57:33  <defunctzombie>haha
22:58:10  <isaacs>Raynos: are you using the 'streams2' package a lot?
22:58:22  <isaacs>Raynos: i'd like to rename the 'readable-stream' module to 'streams2'
22:58:38  <isaacs>Raynos: and make it match require('stream') that you get in core in 0.10
23:00:47  <defunctzombie>sounds like some shit will break haha
23:00:55  <mbalho>chrisdickinson: to summarize, i would like a module that made it easy to publish css with images to npm
23:02:09  <rvagg>mbalho: what sort of structured data are you talking about? is this more government stuff?
23:02:20  <pkrumins>testling now has chrome 24, chrome 25, and firefox 18, firefox 19.
23:02:33  <pkrumins>just added
23:02:59  <rvagg>pkrumins: I need lynx, can you add that? now that I'm browsing kindleberrypi style...
23:03:32  <mbalho>rvagg: mostly tabular data sets, sql exports, GIS data, lots of gov clients + probably open science
23:03:32  <pkrumins>no
23:03:38  <defunctzombie>pkrumins: fuck yea
23:03:40  <Raynos>isaacs: you can the streams2 name
23:03:47  <Raynos>but
23:03:49  <pkrumins>defunctzombie: still fighting for the ssl cert
23:03:53  <defunctzombie>pkrumins: bahahaha
23:04:06  <Raynos>there are no dependants that are not me
23:04:28  <Raynos>isaacs: maybe leave v0.1.1 there on npm and have v1.0 be readable-stream
23:04:54  <Raynos>isaacs: You can also solve this issue by creating a module called `stream2`
23:06:15  <isaacs>Raynos: yeah....
23:06:22  <isaacs>i guess i could call it 'stream2'
23:06:27  <Raynos>but either way
23:06:29  <Raynos>I dont care
23:06:36  <isaacs>in that case, it'd be good to deprecate sterams2 and point people at stream2.Readable.wrap()
23:06:37  <Raynos>i'd just be nice to not unpublish v0.1.1
23:06:40  <isaacs>since it does exctly the same thign
23:06:50  <isaacs>nono, at the very least, we'd leave 0.x where it is, and bump hte major
23:06:58  <Raynos>Thats fine too
23:07:37  <Raynos>I transferred the repo :D
23:09:33  * defunctzombiechanged nick to defunctzombie_zz
23:15:18  <Raynos>http://www.indiegogo.com/projects/tern-intelligent-javascript-editing
23:15:38  <Raynos>substack, isaacs: Are there any limitations with commonJS that would make such a project ^^^ hard?
23:17:37  <Domenic_>Raynos: the usual problems of CommonJS modules not being statically analyzable, unless you're well-behaved
23:17:57  <Domenic_>require(Math.random() > 0.5 ? 'x' : 'y')
23:18:10  <Raynos>is only using `module.exports` and `require({{string literal}})` well behaved?
23:18:20  <Domenic_>not quite
23:18:25  <Domenic_>you also need to guarantee requires are only at top level
23:18:41  <Domenic_>if (Math.random() > 0.5) { require('x') } else { require('y') }
23:18:56  <Raynos>I do that
23:19:13  <Raynos>like http://raynos.graphics-server.jit.su/full/mario.js
23:19:13  * jibayquit (Read error: Connection reset by peer)
23:19:55  <Domenic_>lgtm
23:20:13  <Domenic_>of course, if we had a syntax that enforced those restrictions... ;)
23:20:31  <Raynos>that would be nice
23:20:40  <Raynos>I think es6 should pave the commonJS cowpath
23:20:41  <Raynos>but fuck es6
23:20:47  <Raynos>it can fuck off and die like es4 did
23:20:50  <Raynos>long live es7
23:20:53  <Domenic_>lol
23:20:56  <Domenic_>we'll see.
23:21:16  <Domenic_>i'd rather work with them than take such attitudes
23:21:25  <Domenic_>also you're in the bay area so that's even easier
23:21:26  <Domenic_>but oh well
23:22:34  <Domenic_>you guys should come to https://blog.mozilla.org/research/2013/03/07/mozilla-research-party-april-2-6pm/
23:22:41  <Domenic_>meet dherman in person :P
23:24:42  <substack>maybe I can get through to him why es6 modules are so terrible
23:26:29  <Raynos>Domenic_: thats a good idea
23:26:33  <substack>Domenic_: so here's the thing
23:26:55  <substack>the problem of modules not being statically analyzable is solved with exactly 1 feature: make `import` a keyword like typeof
23:26:58  <substack>bam, done
23:27:23  <substack>the problem is that all of this other unwarranted baggage sneaks in under those auspices
23:27:29  <Domenic_>substack: agree in spirit
23:27:42  <Domenic_>not quite that simple though since `if (false) { import 'foo' }`
23:27:49  <substack>make that an error
23:27:52  <Raynos>thats a syntax error
23:27:57  <substack>yes agreed
23:27:59  <Raynos>just like function declarations in blocks are syntax errors
23:27:59  <Domenic_>sure but now it's not your simple proposal
23:28:05  <Domenic_>Raynos: haha not anymore
23:28:12  <Raynos>THEY SHOULD BE
23:28:22  <Raynos>the problem with import and require
23:28:28  <Raynos>well no
23:28:35  <Raynos>var foo = import {{string}}
23:28:35  <substack>Domenic_: imports at top-level, if import isn't at the top level, syntax error
23:28:38  <substack>pow, so simple
23:28:57  <Domenic_>substack: you can't make that work without *some* special syntax
23:29:05  <Raynos>I just want to be able to use object destructuring with my import syntax
23:29:09  <Domenic_>e.g. `let x = Math.random() > 0.5 ? import 'x' : import 'y'` is still top-level
23:29:12  <substack>Domenic_: I'm already granting that `import` can be a keyword like typeof
23:29:13  <Domenic_>Raynos: AGREED OMG OMG OMG
23:29:21  <Raynos>I need it
23:29:27  <Raynos>Domenic_: http://raynos.graphics-server.jit.su/full/mario.js
23:29:37  <Domenic_>Instead you get this horrific pseudo-destructuring
23:29:39  <Raynos>that should be 4 import statements, not 12
23:29:40  <substack>Domenic_: either syntax error or import both things
23:29:46  <substack>whatever I don't even care which one
23:30:01  <Domenic_>substack: btw you totally told me that about pseudo-destructuring at node summercamp and i didn't believe you but i was wrong sorry
23:30:12  <substack>I did?
23:30:18  <Domenic_>yeah, lol
23:30:29  <Domenic_>if you don't remember it's less embarassing so let's move on :)
23:30:56  <substack>idea
23:31:10  <substack>browserify should just make `import` work the node way™
23:31:25  <chrisdickinson>haha
23:31:33  <Domenic_>ooh i like it
23:31:43  <Domenic_>i mean there will be hella ugly adapters
23:31:44  <chrisdickinson>downside is you have to get node to play nice with the import statement
23:31:55  <substack>and then I will close all pull requests to "fix" import with "es6 is broken"
23:31:57  <Domenic_>if browserify hides the hella ugly adapters we'll be ok
23:32:17  <substack>adapters?
23:32:22  <Domenic_>like the one i made
23:32:28  <Domenic_>or rather outlined
23:32:36  <Domenic_>https://gist.github.com/domenic/4748675
23:32:38  <substack>yes
23:32:43  <substack>so my thinking is: fuck es6
23:32:50  <substack>let's just take the import keyword
23:32:58  <substack>for us
23:33:10  <Raynos>Oh fuck
23:33:13  <Domenic_>hmm
23:33:13  <substack>for our PURPOSES
23:33:15  <Raynos>you cant export a single thing in es6
23:33:16  <Domenic_>so more drastic
23:33:19  <Raynos>God fucking damnit
23:33:23  <Domenic_>Raynos: yes i know wtf wtf wtf
23:33:25  <Domenic_>To be fair
23:33:26  <Raynos>GOD FUCKING DAMN IT >:(
23:33:27  <substack>Raynos: I know right?
23:33:33  <substack>that is like the only thing that should be supported
23:33:34  <Domenic_>They are deferring it for lack of time
23:33:36  <substack>fuck multi-exports
23:33:37  <Raynos>anyway
23:33:39  <Raynos>fuck es6 :D
23:33:39  <Domenic_>And V8 may prototype it ahead of tim
23:33:47  <Domenic_>Yehuda et al are very aware it's important
23:33:55  <Raynos>nah
23:33:57  <Domenic_>but they're trying for a minimal feature set to iterate on first
23:34:01  <substack>nobody on es6 *gets it*
23:34:03  <Domenic_>but they have their priorities backward
23:34:09  <Raynos>They are not trying for a minimal feature set
23:34:11  <chrisdickinson>substack: you thinking of writing a module to transform `import` and `export` and baking it into browserify?
23:34:15  <substack>es6 modules are NOWHERE NEAR minimal
23:34:16  <Raynos>the minimal feature set is a single import and export
23:34:19  <Domenic_>they think minimal = multi, we think minimal = single
23:34:20  <Raynos>and not exporting multiple tokens
23:34:26  <substack>chrisdickinson: sure, a transform plugin
23:34:30  <substack>easy to write actually
23:34:32  <chrisdickinson>yeah
23:34:35  <chrisdickinson>interesting
23:34:52  <Domenic_>yes, "minimal feature set" = "minimal pieces of what they've held as treasured since conceiving modules in the dawn of time"
23:35:02  <chrisdickinson>it'd be interesting to make a module that was both a transform plugin and a require.extension just to make the thing work the same everywhere
23:35:04  <substack>Domenic_: minimal becomes a whole lot moreso when you only export 1 thing
23:35:06  <Domenic_>so namespacey aliasing, multi-export (for static analyzable-ness), etc.
23:35:32  <Domenic_>which is bizarre
23:35:35  <substack>static analysis is so fucking easy
23:35:42  <substack>just fire up esprima and pow you've got an ast to monkey with
23:35:45  <Domenic_>:-/
23:35:48  <Domenic_>don't say things like that
23:35:50  <Domenic_>it makes you look bad
23:35:54  <substack>it's so true!
23:36:00  <Domenic_>if (false) { require('x') }
23:36:06  <chrisdickinson>so, is the thing on the right hand side of `export` an expression or does it have to be an object literal at the moment?
23:36:15  <Domenic_>chrisdickinson: hahahahaha
23:36:18  <Domenic_>it's worse
23:36:23  <Domenic_>it's a microsyntax
23:36:24  <chrisdickinson>oh god.
23:36:55  <Domenic_>precisely three things are allowed: `export { identifier }` `export { identifier.identifier }`, and `export declaration` (e.g. `export let x = 5`)
23:37:14  <chrisdickinson>ah
23:37:24  <Domenic_>sorry
23:37:26  <Domenic_>not quite
23:37:27  <chrisdickinson>so in the latter case the module exports {x: 5}
23:37:45  <chrisdickinson>i'm assuming this because it's the exact opposite of what i'd want that to do
23:37:54  <Domenic_>`export { identifier }` `export { identifier: identifier }`, `export { identifier: identifier.identifier.idenfiier.... }`
23:38:04  <Domenic_>note that things like `export { "foo": 5 }` don't work, just `export { foo: 5 }`
23:38:23  <Domenic_>chrisdickinson: yes -_-
23:38:26  <chrisdickinson>because it has to be a valid javascript variable name, presumably
23:38:38  <Domenic_>remember tc39 thinks of modules as namespaces, not objects
23:38:46  <Domenic_>so things that aren't identifiers can't be namespaced
23:38:58  <Domenic_>like "foo bar"
23:39:05  <Domenic_>there's no way to create a variable named `foo bar`
23:39:09  <chrisdickinson>Domenic_: did you see https://gist.github.com/chrisdickinson/078258c2c80e5cf591a7 ?
23:39:13  <Domenic_>So `export { "foo bar": 5 }` is disallowed
23:39:21  <chrisdickinson>it might be a little outdated
23:39:44  <chrisdickinson>but basically it says "why are we adding syntax when it doesn't fix any of the hard parts of packaging javascript?"
23:39:55  <Domenic_>chrisdickinson: it is pretty inacurate from what i recall
23:39:57  <substack>why the fuck do we need namespaces that is some c++ bullshit
23:40:02  <Domenic_>you didn't take the time to understand the existing proposals
23:40:07  <substack>javascript has function scope
23:40:07  <Domenic_>so you thought they didn't solve any of your problems
23:40:09  <substack>so much better
23:40:30  <chrisdickinson>Domenic_: the Loader api doesn't get to say anything about CORS, does it?
23:40:38  <Domenic_>and it suffers from the usual "new syntax doesn't work in old browsers so fuck new syntax" stuff
23:40:43  <chrisdickinson>yeah
23:40:44  <Domenic_>the loader api works just as <script> tags do.
23:40:44  <substack>if they want namespaces they should use a `namespace` keyword
23:41:03  <rvagg>mbalho: any idea if there's a command to refresh the kindle screen? I find the paperwhite's incomplete screen refreshing gets too messy after a while and I want it to just do a full render
23:41:08  <Domenic_>substack: i agree. but they program in schema and ml or something where modules = C++ namespaces
23:41:39  <substack>they should like program in javascript
23:41:40  <substack>sometime
23:41:43  <substack>it's pretty nice
23:41:47  <Raynos>Ok
23:41:52  <Raynos>my stanse is now officially
23:41:53  <Raynos>fuck es6
23:41:57  <Raynos>let me know when its dead
23:42:00  <Raynos>ill listen to es7
23:42:01  <Domenic_>just modules, c'mon guys
23:42:04  <Raynos>if it includes useful things
23:42:05  <Domenic_>es6 is mostly really nice
23:42:08  <Raynos>no
23:42:09  <Raynos>fuck classes
23:42:14  <Domenic_>it's just sugar
23:42:16  <Raynos>fuck comprehensions
23:42:19  <Raynos>fuck this template bullshit
23:42:21  <Raynos>fuck all new syntax
23:42:22  <chrisdickinson>modules and yet another way to write functions that has different effects on .apply and .call
23:42:23  <Domenic_>template bullshit is amazing
23:42:24  <substack>Domenic_: it's a kitchen sink and I don't care about any of it
23:42:28  <Raynos>why waste time on syntax
23:42:31  <Domenic_>sigh
23:42:32  <substack>Domenic_: I just care that they're fucking up modules really bad
23:42:34  <Domenic_>time to bow out
23:42:34  <Raynos>when we can get first class binary support
23:42:37  <Raynos>and utf support
23:42:43  <rvagg>es6 is overreach, it'll be like java8 and take 10 years to see the light of day; you will all have moved on to the next hotness when it finally comes out
23:42:44  <Domenic_>utf support is in there
23:42:57  <Raynos>anyway
23:43:00  <Domenic_>rvagg: yes, if you're in the browser. in node though it'll be very soon.
23:43:05  <Raynos>I say get rid of all new syntax, replace with macros
23:43:08  <Domenic_>v8 is prototyping generators
23:43:18  <Raynos>thats what es7 will be
23:43:21  <Raynos>once we recover
23:43:24  <rvagg>v8's moving a *lot* slower than spidermonkey
23:43:24  <Domenic_>actually not prototyping, implementing
23:43:25  <chrisdickinson>i do like yield, as i understand it
23:43:28  <Raynos>from the 5 years wasted on es6 :D
23:43:40  <Domenic_>rvagg: agree, it's sad.
23:43:43  <rvagg>give me `let` and I'll be happy
23:43:47  <Domenic_>but there are signs they're picking up the pace
23:44:04  <substack>it's just waterfall
23:44:09  <substack>runs into all the usual traps
23:44:14  <Domenic_>not quite
23:44:27  <Domenic_>because the committee is implementers and they implement before standardizing
23:44:32  <rvagg>macros... I say NO NO NO to macros
23:44:40  <Domenic_>firefox just lets it hang out there, v8 puts it behind flags
23:44:46  <Domenic_>it's somewhat iterative
23:44:55  <Domenic_>as much as you can be when you can never erase mistakes
23:45:00  <substack>Domenic_: but none of them writes lots of modules so they don't care about the right things :(
23:45:01  <Domenic_>(because breaking the web is no good)
23:45:12  <Domenic_>substack: yeah :(
23:45:21  <Raynos>rvagg: I say NO to all syntax except macros
23:45:41  <rvagg>Raynos: macros are for languages with serious deficiencies
23:45:49  <Raynos>no
23:45:55  <rvagg>and you obviously haven't spent much time debugging C++ macro crapp
23:46:04  <chrisdickinson>*hygenic macros
23:46:04  <Raynos>I'm talking LISP macros
23:46:15  <Raynos>I'm talking fuck the language, want a DSL build it
23:46:27  <rvagg>go do clojurescript then
23:46:33  <Raynos>wisp*
23:46:38  <Raynos>clojurescript is so 2012
23:46:43  <rvagg>hipster
23:46:54  <rvagg>raynoscript
23:48:32  <Raynos>the point is if your gonna add new syntax stop and add macros instead
23:48:37  <Raynos>then wait for 3 years of the js macro wars
23:48:42  <Raynos>and pave the syntax cow paths
23:48:49  * Domenic_quit (Remote host closed the connection)
23:49:37  <rvagg>yeah, I suppose that makes a bit of sense if you let the devs in the real world make the cow paths
23:49:40  <ehd>Raynos: aren't macros in a homogenic grammar like a lisp much simpler to define than in something like JS?
23:49:46  <rvagg>instead of the ivory tower implementors
23:50:11  <substack>rvagg: but the functional programming hipsters on es6 know best! they've proved their thing correct!
23:50:34  <rvagg>Raynos: you're going to dublin at the end of the month? I think I might be going; just have to see if I can get flights that don't kill me
23:51:27  <ralphtheninja>rvagg: cool, then we can swing a few beers :)
23:51:38  <rvagg>substack: I suspect that the es wiki is full of mathematical proofs of their correctness
23:51:55  <rvagg>ralphtheninja: I might be cutting it fine re timing so I'll probably be severely jetlagged
23:53:30  <rvagg>substack: can you make it to dublin?
23:53:30  <ralphtheninja>hehe
23:53:43  <rvagg>I'm guessing that cian has already spoken to you
23:54:56  <substack>rvagg: I already have 2 other prior engagements around the same time
23:55:26  <ralphtheninja>so you decided to ditch them and go to Ireland instead?
23:55:30  <rvagg>oh sad!
23:55:31  * thl0quit (Remote host closed the connection)
23:56:00  <ralphtheninja>yeah thats a bummer
23:57:31  * tilgoviquit (Ping timeout: 245 seconds)