The FileAPI Prototype Gets Updated

I am happy to let you know that today we have made available an update to the FileAPI prototype we released on HTML5 Labs last month.

The Interoperability team at Microsoft developed the File API prototype, which is based on the evolving  W3C specification that provides an API for representing file objects in web applications.

This update implements  the changed behavior in File.slice explained by a note in the latest version of the w3c spec:

The slice method previously had different semantics, which differed from both Array.prototype.slice and String.prototype.slice [ECMA-262]. This difference was an oversight which has been corrected in this edition of the specification. Some user agents implemented the previous semantics, notably Firefox 4, Chrome 10, and Opera 11. These user agents have agreed to vendor-prefix their slice implementations in subsequent releases.

We also included a minor update to the existing features by adding support for selecting and reading multiple files sequentially via the FileList Interface.

The prototype includes a simple demo that shows how FileAPIs can be used to select images on the local machines, preview them on the browsers, and it can easily extended to add the ability to upload the images on the server.

As you may know, HTML5 Labs is the place where Microsoft prototypes early and unstable specifications from web standards bodies such as W3C. Sharing these prototypes helps us have informed discussions with developer communities, and enables us to provide better feedback on draft specifications based on this implementation experience.

So far, we have released three updates to our WebSockets prototype since it was released on the HTML5 Labs site in December, the IndexedDB prototype has been updated to bring it in line with the latest version of the specification, and we recently added a new WebSockets demo.

Coming next is the Media Capture API prototype, a draft specification that defines HTML form enhancements to provide access to the audio, image and video capture capabilities of a device. The first release of the prototype includes Audio capabilities only, but we plan to add video support shortly after the release of the first version. So, stay tuned for the Media Capture  prototype and other new ones that we are working on right now.


Claudio Caldato,

Principal Program Manager, Interoperability Strategy Team

Comments (0)

Skip to main content