|
2 | 2 | "name": "react-on-rails", |
3 | 3 | "version": "15.0.0-alpha.2", |
4 | 4 | "description": "react-on-rails JavaScript for react_on_rails Ruby gem", |
5 | | - "main": "node_package/lib/ReactOnRails.full.js", |
| 5 | + "main": "node_package/lib/esm/ReactOnRails.full.js", |
6 | 6 | "type": "commonjs", |
7 | 7 | "exports": { |
8 | 8 | ".": { |
9 | | - "react-server": "./node_package/lib/ReactOnRailsRSC.js", |
10 | | - "node": "./node_package/lib/ReactOnRails.node.js", |
11 | | - "default": "./node_package/lib/ReactOnRails.full.js" |
| 9 | + "react-server": { |
| 10 | + "import": "./node_package/lib/esm/ReactOnRailsRSC.js", |
| 11 | + "require": "./node_package/lib/cjs/ReactOnRailsRSC.js" |
| 12 | + }, |
| 13 | + "node": { |
| 14 | + "import": "./node_package/lib/esm/ReactOnRails.node.js", |
| 15 | + "require": "./node_package/lib/cjs/ReactOnRails.node.js" |
| 16 | + }, |
| 17 | + "default": { |
| 18 | + "import": "./node_package/lib/esm/ReactOnRails.full.js", |
| 19 | + "require": "./node_package/lib/cjs/ReactOnRails.full.js" |
| 20 | + } |
12 | 21 | }, |
13 | | - "./client": "./node_package/lib/ReactOnRails.client.js", |
14 | | - "./registerServerComponent/client": "./node_package/lib/registerServerComponent/client.js", |
15 | | - "./registerServerComponent/server": "./node_package/lib/registerServerComponent/server.js" |
| 22 | + "./client": { |
| 23 | + "import": "./node_package/lib/esm/ReactOnRails.client.js", |
| 24 | + "require": "./node_package/lib/cjs/ReactOnRails.client.js" |
| 25 | + }, |
| 26 | + "./registerServerComponent/client": { |
| 27 | + "import": "./node_package/lib/esm/registerServerComponent/client.js", |
| 28 | + "require": "./node_package/lib/cjs/registerServerComponent/client.js" |
| 29 | + }, |
| 30 | + "./registerServerComponent/server": { |
| 31 | + "import": "./node_package/lib/esm/registerServerComponent/server.js", |
| 32 | + "require": "./node_package/lib/cjs/registerServerComponent/server.js" |
| 33 | + } |
16 | 34 | }, |
17 | 35 | "directories": { |
18 | 36 | "doc": "docs" |
|
75 | 93 | "prepack": "nps build.prepack", |
76 | 94 | "prepare": "nps build.prepack", |
77 | 95 | "prepublishOnly": "yarn run build", |
78 | | - "build": "yarn run clean && yarn run tsc --declaration", |
79 | | - "build-watch": "yarn run clean && yarn run tsc --watch", |
| 96 | + "build": "node_package/scripts/build", |
| 97 | + "build-watch": "yarn run clean && yarn run tsc --watch --no-declaration", |
80 | 98 | "lint": "nps eslint", |
81 | 99 | "check": "yarn run lint && yarn run test && yarn run type-check", |
82 | 100 | "type-check": "yarn run tsc --noEmit --noErrorTruncation", |
|
0 commit comments