@zenfs/dom 0.0.2 → 0.0.3

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@zenfs/dom",
3
- "version": "0.0.2",
3
+ "version": "0.0.3",
4
4
  "description": "DOM backends for ZenFS",
5
5
  "main": "dist/index.js",
6
6
  "types": "dist",
@@ -26,6 +26,13 @@
26
26
  "exports": {
27
27
  "./*": "./dist/*"
28
28
  },
29
+ "typesVersions": {
30
+ "*": {
31
+ "*": [
32
+ "./dist/*"
33
+ ]
34
+ }
35
+ },
29
36
  "scripts": {
30
37
  "format": "prettier --write src",
31
38
  "format:check": "prettier --check src",
@@ -55,6 +62,6 @@
55
62
  "typescript": "5.2.2"
56
63
  },
57
64
  "dependencies": {
58
- "@zenfs/core": "^0.0.6"
65
+ "@zenfs/core": "^0.0.8"
59
66
  }
60
67
  }
package/readme.md CHANGED
@@ -19,22 +19,15 @@ For more information, see the [API documentation](https://zen-fs.github.io/fs-do
19
19
  npm install @zenfs/fs-dom
20
20
  ```
21
21
 
22
- ## Building
23
-
24
- - Make sure you have Node and NPM installed. You must have Node v18 or newer.
25
- - Install dependencies with `npm install`
26
- - Build using `npm run build`
27
- - You can find the built code in `dist`.
28
-
29
22
  ## Usage
30
23
 
31
- > 🛈 The examples are written in ESM. If you are using CJS, you can `require` the package. If running in a borwser you can add a script tag to your HTML pointing to the `browser.min.js` and use ZenFS DOM via the global `ZenFS_DOM` object.
24
+ > 🛈 The examples are written in ESM. If you are using CJS, you can `require` the package. If running in a browser you can add a script tag to your HTML pointing to the `browser.min.js` and use ZenFS DOM via the global `ZenFS_DOM` object.
32
25
 
33
26
  You can use DOM backends, though you must register them if you plan on using `configure`:
34
27
 
35
28
  ```js
36
29
  import { configure, fs, registerBackend } from '@zenfs/core';
37
- import { Storage } '@zenfs/fs-dom';
30
+ import { Storage } from '@zenfs/fs-dom';
38
31
 
39
32
  registerBackend(Storage);
40
33
  await configure({ fs: 'Storage', options: { storage: localStorage } });
@@ -46,7 +39,3 @@ if (!fs.existsSync('/test.txt')) {
46
39
  const contents = fs.readFileSync('/test.txt', 'utf-8');
47
40
  console.log(contents);
48
41
  ```
49
-
50
- ### Testing
51
-
52
- Run unit tests with `npm test`.