Skip to content

Commit f3c269e

Browse files
committedMay 31, 2024
cleaned up @fobx/react for publishing
1 parent 9608a60 commit f3c269e

File tree

4 files changed

+35
-11
lines changed

4 files changed

+35
-11
lines changed
 

‎.cspell.json

+1-1
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33
"language": "en",
44
"useGitignore": true,
55
// words - list of words to be always considered correct
6-
"words": ["autorun", "tinybench", "iterall", "fobx", "klas"],
6+
"words": ["autorun", "tinybench", "iterall", "fobx", "klas", "outdir"],
77
// flagWrods - words to always consider mispelled
88
"flagWords": ["hte"],
99
"ignorePaths": ["./.cspell.json"]

‎packages/react/README.md

+4
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,4 @@
1+
# @fobx/react
2+
3+
This package contains the React higher order function reaction that re-renders react component in reaction to a fobx
4+
state change.

‎packages/react/build.mjs

+2-4
Original file line numberDiff line numberDiff line change
@@ -13,9 +13,9 @@ function gzip(input, options) {
1313
return promise;
1414
}
1515

16-
const NAME = "fobx-react";
16+
const NAME = "index";
1717
const DIR = "./dist";
18-
const ESM_EXT = ".esm.js";
18+
const ESM_EXT = ".js";
1919
const CJS_EXT = ".cjs.js";
2020

2121
// make sure dist folder doesn't contain anything out of date
@@ -36,9 +36,7 @@ const writeBundle = (extension) => {
3636
"process.env.NODE_ENV": '"production"',
3737
},
3838
external: ["@fobx/core", "react"],
39-
sourcemap: true,
4039
minify: false,
41-
keepNames: true,
4240
outfile: `${DIR}/${NAME}${extension}`,
4341
});
4442
};

‎packages/react/package.json

+28-6
Original file line numberDiff line numberDiff line change
@@ -1,16 +1,38 @@
11
{
22
"name": "@fobx/react",
33
"version": "0.1.0",
4-
"description": "",
5-
"main": "src/index.ts",
4+
"license": "BSD-3-Clause",
5+
"author": "Jeremy Klas",
6+
"description": "React higher order function reaction.",
7+
"keywords": [
8+
"fobx",
9+
"reactive",
10+
"observable",
11+
"react",
12+
"functional-reactive-programming",
13+
"dependency free",
14+
"state management"
15+
],
16+
"homepage": "https://github.com/jereklas/fobx#readme",
17+
"repository": {
18+
"type": "git",
19+
"url": "https://github.com/jereklas/fobx.git"
20+
},
21+
"bugs": {
22+
"url": "https://github.com/jereklas/fobx/issues"
23+
},
24+
"main": "dist/index.cjs.js",
25+
"module": "dist/index.js",
26+
"types": "dist/types/index.d.ts",
627
"scripts": {
7-
"build": "node ./build.mjs && tsc"
28+
"build": "node ./build.mjs && tsc",
29+
"prepublish": "pnpm build"
830
},
931
"peerDependencies": {
10-
"@fobx/core": "workspace:*"
32+
"@fobx/core": ">=0.1.0",
33+
"react": ">=18"
1134
},
1235
"files": [
13-
"dist",
14-
"src"
36+
"dist"
1537
]
1638
}

0 commit comments

Comments
 (0)
Please sign in to comment.