by

Where communities thrive


  • Join over 1.5M+ people
  • Join over 100K+ communities
  • Free without limits
  • Create your own community
People
Activity
  • May 23 12:06
  • May 23 11:51
    craigtaub synchronize #4245
  • May 23 11:51

    craigtaub on master

    update CHANGELOG for v7.2.0 [ci… Release v7.2.0 (compare)

  • May 23 11:42

    craigtaub on mochajs.org

    remove cruft from wallaby confi… refactor Test: add markOnly() f… enable emoji on website; enable… and 30 more (compare)

  • May 23 11:14
    Travis mochajs/mocha@2aab607 (v7.2.0) passed (7502)
  • May 23 11:09

    craigtaub on v7.2.x

    Release v7.2.0 (compare)

  • May 23 11:02

    craigtaub on v7.2.0

    Release v7.2.0 (compare)

  • May 23 11:00

    craigtaub on v7.2.x

    update CHANGELOG for v7.2.0 [ci… (compare)

  • May 23 09:31
    Travis mochajs/mocha@171bbe5 (munter/sprite-opencollective-avatars) passed (7501)
  • May 23 09:20

    Munter on sprite-opencollective-avatars

    Generate sprite sheets from ope… (compare)

  • May 23 07:49
    outsideris unlabeled #4011
  • May 23 07:45
    outsideris closed #4277
  • May 22 22:45
  • May 22 22:41
    Travis mochajs/mocha (boneskull/issue/2839-parallel) still failing (7499)
  • May 22 22:31
    boneskull synchronize #4245
  • May 22 22:31

    boneskull on issue

    create utils.isBrowser() wrappe… remove weird timeouts in test/i… refactor test/integration/fixtu… and 3 more (compare)

  • May 22 17:58
    Travis mochajs/mocha (boneskull/rename-smoke-test) fixed (7497)
  • May 22 17:48
    boneskull labeled #4300
  • May 22 17:48
    boneskull labeled #4300
  • May 22 17:48
    boneskull assigned #4300
Peter Müller
@Munter
This would let js run just fine, while giving bundlers an instruction that this external file is a part of the depencency graph, and deal with it appropriately
I Assetgraph we had to invent our own dumpsterfire of a syntax in order to let you declare external dpendencies in js: 'stringLiteral'.toString('url')
Craig Taub
@craigtaub
is there anything like that in tc39 proposal?
Peter Müller
@Munter
This makes Assetgraph discover that string literal as a file reference and add it to the dependency graph and update the string literal with any url updates the file might get
There are forces working against this simple proposal becasue they feel it would invalidate their much more complex proposal to be able to load css, json etc as a module, being able to consume either the raw text or an ast depending on context etc
Peter Müller
@Munter
Yup, things like that. JS developers want references to build artifacts from their included non-js non-modules. So complex proposals arrive
But the simple concept of annotating this file depends on this other file. Nope
Take all of that away, and tool interop becaomes extremely simple again
Nico Jansen
@nicojs

So in conclusion:

So instead of adding preprocessors to mocha, we should create a new TS39 proposal for external ... from '' syntax.

<insert scope creep meme here> 😉
Peter Müller
@Munter
This is one of my primary motivations for experimenting with pulling transpiler pipelines into the file system, so we can skip the duplicate configuration of loaders for every single tool: https://www.youtube.com/watch?v=MptY6ff4tOQ
Nico Jansen
@nicojs
(just joking, I'm not for/against it)
Craig Taub
@craigtaub
interesting, ill have a watch
Nico Jansen
@nicojs
Interesting @Munter I've watched your presentation. Awesome! Did you're idea of using the file system as an abstraction for transpilers gained traction?
Peter Müller
@Munter
It did not. I had a few people approach me about the idea, including some of the people from Bloomberg who put a lot of work into js module standardisation. But ultimately the fuse libraries for node were a bit young and unstable, there wasn't any multithreading, and I just didn't have any time to keep working on it
There's also this problem that some applications, like web servers, can depend on knowing the length of a file to set it in response headers. This happens by calling a stat on the file first. If the size is reported wrong, the whole http stream becomes buggy. This meant I had to switch from initiating work upon file read to do it on stat, which also meant that the concept of work on demand was completely killed, because operating systems have all sorts of indexing services running stat calls on all sorts of files all the time. Especially freshly mounted file systems. All performance benefits from skipping work were just non-existent
Nico Jansen
@nicojs
yeah... file system might be a bit too low-level, but web server is too high-level. Need something in between I think
Peter Müller
@Munter
I think there is multithreading in the node bindings now. And if a cache concept could be introduced that wouldn't throw away the previous work upon unmount, then maybe the file stats wouldn't a problem any more. Imagine havign your whole company running mounted file systems backed by a shared redis cache, so you essentially have completely distributed shared caching of all files across the company
Nico Jansen
@nicojs
Wow, you've obviously put a lot of thought into this.
Still... file system is pretty low level. A lot of calls to intercept, no?
I like the typescript concept of "hosts"
Peter Müller
@Munter
The ideas are not entirely new. Stuff like this has just only been explored internally at very large companies that had the resources to make it work and had the biggest gains from doing it
Nico Jansen
@nicojs
But still, you would need the external from syntax or something like that to get around the dependency graph problem, right?
Peter Müller
@Munter
There are a fe calls, yes. But it's a reasonable amount of boiler plate. https://github.com/Munter/fusile/blob/master/lib/index.js
The dependency graph problem is separate. Related in case of frontend development, but both things would have value solved separately
Nico Jansen
@nicojs
true
Peter Müller
@Munter
It is kind of ironic that literally every type of web asset has the ability to syntactically define references to other related files, except for javascript.
require() was just a convention. Literally anything other than es modules has been completely runtime implemented or environment dependent. And even with modules, we can only include js modules, not reference anything else
Nico Jansen
@nicojs
What's your opinion on loaders in nodejs? https://nodejs.org/api/esm.html#esm_experimental_loaders
Peter Müller
@Munter
They won't work in the browser. Yet another environment specific thing that will require post-processing of files in order to run them in a browser
My idea of external imageUrl from './path/to/image.jpg' would work though. Because in my favorite abstraction I can go <img src="${imageUrl}">
No bundler or loader needed
A bundler might be able to add value on top, for renaming files to be content addressable for example. But not required
It could even inline: external imageUrl from 'base64:...';
Peter Müller
@Munter
Heck, I could even pick this up through static analysis and rewrite it to a sprite sheet. But alas, the ecosystem is missing
Nico Jansen
@nicojs
Yeah that's my opinion as well. ESM loaders sound just seem like another require.extensions
Craig Taub
@craigtaub
Oh boy. 7.2.0 now got a failure on the node v8 tests, the ones which are dropped in master.
see: https://travis-ci.org/github/mochajs/mocha/builds/690030122
Replicated locally.
Craig Taub
@craigtaub
Update on release issue.
We moved to fs-extra v9 few months ago. v9 does not support nodejs v8. As we need to continue supporting nodejs v8 for our 7.x release branch I am downgrading that dep for this release branch.
If anyone has any thoughts on this pls let me know. Im doing what I think is correct
Peter Müller
@Munter
I agree with that call @craigtaub . The only reason to upgrade is probably security audit stuff, and on node8 noone can expect to get the latest security updates anymore anyway
Craig Taub
@craigtaub
Cool, cheers man.
Craig Taub
@craigtaub
v7.2.0 is now published
Craig Taub
@craigtaub
incl docs etc.
Nico Jansen
@nicojs
Awesome! My first feature released 🎉 Root hooks is also a good improvement. We should write a blog about it.
Craig Taub
@craigtaub
Congrats man. Blog post a gr8 idea
Nico Jansen
@nicojs
Maybe we can create one for v8 release, including --parallel mode? Are there plans for that?
Craig Taub
@craigtaub
Not that I know of.
Nico Jansen
@nicojs
If not, I'd be happy to write a blog article about it