vite-plugin-rnw 0.0.3 → 0.0.4

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.
Files changed (2) hide show
  1. package/README.md +12 -3
  2. package/package.json +9 -9
package/README.md CHANGED
@@ -1,6 +1,8 @@
1
1
  # vite-plugin-rnw
2
2
 
3
- A vite plugin for React Native Web projects. (edited from a version of the react plugin)
3
+ A vite plugin for React Native Web projects.
4
+
5
+ This plugin is based on the [react plugin](https://github.com/vitejs/vite-plugin-react/blob/main/packages/plugin-react/README.md)
4
6
 
5
7
  - enable [Fast Refresh](https://www.npmjs.com/package/react-refresh) in development (requires react >= 16.9)
6
8
  - use the [automatic JSX runtime](https://legacy.reactjs.org/blog/2020/09/22/introducing-the-new-jsx-transform.html)
@@ -32,8 +34,15 @@ export default defineConfig({
32
34
  });
33
35
  ```
34
36
 
35
- > `node_modules` can be processed by this plugin when needed
36
- > the excludes default is `/\/node_modules\/(?!react-native|@react-native|expo|@expo)/;`
37
+ `node_modules` can be processed by this plugin when needed
38
+
39
+ By default the excludes pattern is:
40
+
41
+ ```js
42
+ /\/node_modules\/(?!react-native|@react-native|expo|@expo)/;
43
+ ```
44
+
45
+ This means any package that starts with react-native, @react-native, expo, or @expo will be included and other node_modules will be excluded. But you can change this to include or exclude any package you want.
37
46
 
38
47
  ### jsxImportSource
39
48
 
package/package.json CHANGED
@@ -1,5 +1,5 @@
1
1
  {
2
- "version": "0.0.3",
2
+ "version": "0.0.4",
3
3
  "name": "vite-plugin-rnw",
4
4
  "type": "module",
5
5
  "main": "./dist/index.cjs",
@@ -39,26 +39,26 @@
39
39
  },
40
40
  "devDependencies": {
41
41
  "@types/node": "^22",
42
- "tsdown": "^0.12.9",
43
- "vite": "^7.0.4",
44
42
  "babel-plugin-react-compiler": "19.1.0-rc.2",
45
43
  "react": "^19.1.0",
46
44
  "react-dom": "^19.1.0",
47
- "rolldown": "1.0.0-beta.24"
45
+ "rolldown": "1.0.0-beta.24",
46
+ "tsdown": "^0.12.9",
47
+ "vite": "^7.0.4"
48
48
  },
49
49
  "peerDependencies": {
50
+ "react-native-web": "*",
50
51
  "typescript": "^5",
51
- "vite": "^4.2.0 || ^5.0.0 || ^6.0.0 || ^7.0.0",
52
- "react-native-web": "*"
52
+ "vite": "^4.2.0 || ^5.0.0 || ^6.0.0 || ^7.0.0"
53
53
  },
54
54
  "dependencies": {
55
- "vite-plugin-commonjs": "^0.10.4",
56
- "@babel/plugin-transform-modules-commonjs": "^7.27.1",
57
55
  "@babel/core": "^7.28.0",
56
+ "@babel/plugin-transform-modules-commonjs": "^7.27.1",
58
57
  "@babel/plugin-transform-react-jsx-self": "^7.27.1",
59
58
  "@babel/plugin-transform-react-jsx-source": "^7.27.1",
60
59
  "@rolldown/pluginutils": "1.0.0-beta.24",
61
60
  "@types/babel__core": "^7.20.5",
62
- "react-refresh": "^0.17.0"
61
+ "react-refresh": "^0.17.0",
62
+ "vite-plugin-commonjs": "^0.10.4"
63
63
  }
64
64
  }