jvilk / BrowserFS

BrowserFS is an in-browser filesystem that emulates the Node JS filesystem API and supports storing and retrieving files from various backends.
Other
3.07k stars 220 forks source link

Build a browserfs.js standalone library #29

Closed perimosocordiae closed 11 years ago

perimosocordiae commented 11 years ago

This is a requirement for the newly-minted doppio-demo repository.

I can see this happening in two ways:

  1. Select which FS types you want, then bundle them into a compressed JS file.
  2. Throw the whole kitchen sink of FS types in, and let the library user select the configuration at startup.
jvilk commented 11 years ago

I'm confused about this issue. Do a make release, then look at lib/browserfs.min.js. It contains all of the file systems. The developer chooses the configuration at startup, and determines whether or not to install global variables (like require).

See 000-browserfs.coffee for details.

jvilk commented 11 years ago

Also, if I switch BrowserFS to TypeScript, supporting the 1st case is easy -- TypeScript already automatically determines which modules are used / need to be bundled, so you would simply perform tsc 000-browserfs.ts [list of FS to compile].

perimosocordiae commented 11 years ago

Yeah, I think the current state of the project is ok. I'll close this after we get BFS working with Doppio correctly.

jvilk commented 11 years ago

Closing -- BFS works with Doppio, but fails in IE9 at the moment (see bug #36).