@yaasl/react 0.10.2 → 0.11.0-alpha.1

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.
@@ -1,4 +1,4 @@
1
- import { Stateful } from "@yaasl/core";
1
+ import type { Stateful } from "@yaasl/core";
2
2
  /** Use an atom's value in the react lifecycle.
3
3
  *
4
4
  * @param atom Atom to be used.
@@ -1,4 +1,4 @@
1
1
  import { SetStateAction } from "react";
2
- import { Stateful } from "@yaasl/core";
2
+ import type { Stateful } from "@yaasl/core";
3
3
  export declare const useStatefulValue: <ValueType>(stateful: Stateful<ValueType>) => ValueType;
4
4
  export declare const useSetStateful: <ValueType>(stateful: Stateful<ValueType>) => (next: SetStateAction<ValueType>) => void;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@yaasl/react",
3
- "version": "0.10.2",
3
+ "version": "0.11.0-alpha.1",
4
4
  "description": "yet another atomic store library (react)",
5
5
  "author": "PrettyCoffee",
6
6
  "license": "MIT",
@@ -17,18 +17,20 @@
17
17
  "bugs": {
18
18
  "url": "https://github.com/PrettyCoffee/yaasl/issues"
19
19
  },
20
+ "sideEffects": false,
20
21
  "main": "./dist/cjs/index.js",
22
+ "module": "./dist/esm/index.js",
21
23
  "types": "./dist/@types/index.d.ts",
22
24
  "exports": {
23
25
  "types": "./dist/@types/index.d.ts",
24
- "import": "./dist/mjs/index.js",
25
- "require": "./dist/cjs/index.js"
26
+ "require": "./dist/cjs/index.js",
27
+ "default": "./dist/esm/index.js"
26
28
  },
27
29
  "scripts": {
28
30
  "build": "run-s clean compile",
29
31
  "clean": "rimraf ./dist",
30
- "compile": "run-p compile:mjs compile:cjs compile:types",
31
- "compile:mjs": "tsc -p ./tsconfig.node.json --outDir ./dist/mjs -m esnext -t esnext",
32
+ "compile": "run-p compile:esm compile:cjs compile:types",
33
+ "compile:esm": "tsc -p ./tsconfig.node.json --outDir ./dist/esm -m esnext -t esnext",
32
34
  "compile:cjs": "tsc -p ./tsconfig.node.json --outDir ./dist/cjs -m commonjs -t es2015",
33
35
  "compile:types": "tsc -p ./tsconfig.node.json --outDir ./dist/@types --declaration --emitDeclarationOnly",
34
36
  "test": "vitest run",
@@ -41,12 +43,12 @@
41
43
  "react": ">=17"
42
44
  },
43
45
  "dependencies": {
44
- "@yaasl/core": "0.10.2",
45
- "@yaasl/utils": "0.10.2"
46
+ "@yaasl/core": "0.11.0-alpha.1",
47
+ "@yaasl/utils": "0.11.0-alpha.1"
46
48
  },
47
49
  "devDependencies": {
48
50
  "@testing-library/react": "^14.3.1",
49
- "@types/react": "^18.3.11",
51
+ "@types/react": "^18.3.12",
50
52
  "react": "^18.3.1"
51
53
  },
52
54
  "eslintConfig": {
File without changes
File without changes
File without changes