filer/examples/idbfs-test.html

43 lines
706 B
HTML
Raw Normal View History

2012-10-07 05:42:58 +00:00
<!DOCTYPE HTML>
<html>
<head>
<meta charset="utf-8" />
</head>
2012-10-11 06:20:58 +00:00
<body>
<div id="stdout"></div>
</body>
2012-10-07 05:42:58 +00:00
<script src="../lib/require.js"></script>
<script>
require.config({
baseUrl: "../lib",
paths: {
"src": "../src"
}
});
2012-11-08 05:12:41 +00:00
require(["src/fs"], function(IDBFS) {
2012-10-11 06:20:58 +00:00
2012-11-08 05:12:41 +00:00
IDBFS.mount("default", "FORMAT", function(error, fs) {
if(error) {
console.error(error);
return;
}
fs.mkdir("/tmp", function() {
if(error) {
console.error(error);
return;
}
fs.stat("/tmp", function(error, result) {
if(error) {
console.error(error);
return;
}
console.info(result);
});
2012-10-11 06:20:58 +00:00
});
2012-11-08 05:12:41 +00:00
});
2012-10-11 06:20:58 +00:00
2012-10-07 05:42:58 +00:00
});
</script>
2012-10-15 15:33:56 +00:00
</html>