react-native-electron-platform 0.0.4 → 0.0.5
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/CHANGELOG.md +1 -1
- package/CONTRIBUTING.md +2 -2
- package/LICENSE +2 -18
- package/README.md +6 -7
- package/package.json +4 -4
- package/src/webpackConfigHelper.mjs +1 -1
- package/test/test.mjs +27 -0
package/CHANGELOG.md
CHANGED
|
@@ -8,7 +8,7 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
|
|
|
8
8
|
## [1.0.0] - 2024-02-24
|
|
9
9
|
|
|
10
10
|
### Added
|
|
11
|
-
- Initial release of react-native-electron boilerplate
|
|
11
|
+
- Initial release of react-native-electron-platform boilerplate
|
|
12
12
|
- Electron main process with auto-updater
|
|
13
13
|
- Preload script for secure IPC communication
|
|
14
14
|
- Webpack configuration helper for React Native web builds
|
package/CONTRIBUTING.md
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
# Contributing to react-native-electron
|
|
1
|
+
# Contributing to react-native-electron-platform
|
|
2
2
|
|
|
3
|
-
Thank you for your interest in contributing to react-native-electron! We welcome contributions from the community.
|
|
3
|
+
Thank you for your interest in contributing to react-native-electron-platform! We welcome contributions from the community.
|
|
4
4
|
|
|
5
5
|
## How to Contribute
|
|
6
6
|
|
package/LICENSE
CHANGED
|
@@ -1,21 +1,5 @@
|
|
|
1
|
-
MIT License
|
|
2
|
-
|
|
3
1
|
Copyright (c) 2024 JESCON TECHNOLOGIES PVT LTD
|
|
4
2
|
|
|
5
|
-
|
|
6
|
-
of this software and associated documentation files (the "Software"), to deal
|
|
7
|
-
in the Software without restriction, including without limitation the rights
|
|
8
|
-
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
|
9
|
-
copies of the Software, and to permit persons to whom the Software is
|
|
10
|
-
furnished to do so, subject to the following conditions:
|
|
11
|
-
|
|
12
|
-
The above copyright notice and this permission notice shall be included in all
|
|
13
|
-
copies or substantial portions of the Software.
|
|
3
|
+
All rights reserved.
|
|
14
4
|
|
|
15
|
-
|
|
16
|
-
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
|
17
|
-
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
|
18
|
-
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
|
19
|
-
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
|
20
|
-
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
|
21
|
-
SOFTWARE.
|
|
5
|
+
This software is proprietary and confidential. Unauthorized copying, modification, distribution, or use is strictly prohibited.
|
package/README.md
CHANGED
|
@@ -1,8 +1,7 @@
|
|
|
1
|
-
# react-native-electron
|
|
1
|
+
# react-native-electron-platform
|
|
2
2
|
|
|
3
|
-
[](https://badge.fury.io/js/react-native-electron)
|
|
4
|
-
[](https://github.com/dpraful/react-native-electron/actions)
|
|
3
|
+
[](https://badge.fury.io/js/react-native-electron-platform)
|
|
4
|
+
[](https://github.com/dpraful/react-native-electron-platform/actions)
|
|
6
5
|
|
|
7
6
|
A boilerplate and utility library for running React Native applications in Electron, supporting both desktop and web platforms.
|
|
8
7
|
|
|
@@ -19,7 +18,7 @@ A boilerplate and utility library for running React Native applications in Elect
|
|
|
19
18
|
## Installation
|
|
20
19
|
|
|
21
20
|
```bash
|
|
22
|
-
npm install react-native-electron
|
|
21
|
+
npm install react-native-electron-platform
|
|
23
22
|
```
|
|
24
23
|
|
|
25
24
|
## Usage
|
|
@@ -32,7 +31,7 @@ npm install react-native-electron
|
|
|
32
31
|
### As a Library
|
|
33
32
|
|
|
34
33
|
```javascript
|
|
35
|
-
import { categorizePackages, isWebSupported } from 'react-native-electron';
|
|
34
|
+
import { categorizePackages, isWebSupported } from 'react-native-electron-platform';
|
|
36
35
|
|
|
37
36
|
const packages = categorizePackages();
|
|
38
37
|
// Use the categorized packages for your build configuration
|
|
@@ -74,4 +73,4 @@ See [CHANGELOG.md](CHANGELOG.md) for a list of changes and version history.
|
|
|
74
73
|
|
|
75
74
|
## License
|
|
76
75
|
|
|
77
|
-
This project is
|
|
76
|
+
This project is proprietary software owned by JESCON TECHNOLOGIES PVT LTD. All rights reserved. Unauthorized use, copying, modification, or distribution is prohibited.
|
package/package.json
CHANGED
|
@@ -1,12 +1,12 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "react-native-electron-platform",
|
|
3
|
-
"version": "0.0.
|
|
3
|
+
"version": "0.0.5",
|
|
4
4
|
"description": "A boilerplate and utilities for running React Native applications in Electron",
|
|
5
5
|
"main": "index.mjs",
|
|
6
6
|
"scripts": {
|
|
7
7
|
"start": "electron src/main.mjs",
|
|
8
8
|
"build": "webpack --config webpack.config.mjs",
|
|
9
|
-
"test": "
|
|
9
|
+
"test": "node test/test.mjs"
|
|
10
10
|
},
|
|
11
11
|
"keywords": [
|
|
12
12
|
"react-native",
|
|
@@ -15,8 +15,8 @@
|
|
|
15
15
|
"web",
|
|
16
16
|
"boilerplate"
|
|
17
17
|
],
|
|
18
|
-
"author": "
|
|
19
|
-
"license": "
|
|
18
|
+
"author": "PRAFULDAS M M",
|
|
19
|
+
"license": "JESCON TECHNOLOGIES PVT LTD",
|
|
20
20
|
"repository": {
|
|
21
21
|
"type": "git",
|
|
22
22
|
"url": "https://github.com/dpraful/react-native-electron-platform.git"
|
|
@@ -2,7 +2,7 @@ import path from 'path';
|
|
|
2
2
|
import { fileURLToPath } from 'url';
|
|
3
3
|
import { dirname } from 'path';
|
|
4
4
|
import fs from 'fs';
|
|
5
|
-
import { WEB_UNSUPPORTED_PACKAGES } from '
|
|
5
|
+
import { WEB_UNSUPPORTED_PACKAGES } from '../test/electron/nonmodules.mjs';
|
|
6
6
|
|
|
7
7
|
const __dirname = dirname(fileURLToPath(import.meta.url));
|
|
8
8
|
|
package/test/test.mjs
ADDED
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
import { getAllPackages, categorizePackages, isWebSupported, generateAlias, generateFallback } from '../src/webpackConfigHelper.mjs';
|
|
2
|
+
import { WEB_UNSUPPORTED_PACKAGES } from './nonmodules.mjs';
|
|
3
|
+
|
|
4
|
+
console.log('Testing webpackConfigHelper...');
|
|
5
|
+
|
|
6
|
+
// Test getAllPackages
|
|
7
|
+
const allPackages = getAllPackages();
|
|
8
|
+
console.log('All packages:', Object.keys(allPackages));
|
|
9
|
+
|
|
10
|
+
// Test categorizePackages
|
|
11
|
+
const { webSupported, webUnsupported } = categorizePackages();
|
|
12
|
+
console.log('Web supported:', webSupported.length);
|
|
13
|
+
console.log('Web unsupported:', webUnsupported.length);
|
|
14
|
+
|
|
15
|
+
// Test isWebSupported
|
|
16
|
+
console.log('react-native-web supported:', isWebSupported('react-native-web'));
|
|
17
|
+
console.log('react-native-fs supported:', isWebSupported('react-native-fs'));
|
|
18
|
+
|
|
19
|
+
// Test generateAlias
|
|
20
|
+
const alias = generateAlias();
|
|
21
|
+
console.log('Alias keys:', Object.keys(alias));
|
|
22
|
+
|
|
23
|
+
// Test generateFallback
|
|
24
|
+
const fallback = generateFallback();
|
|
25
|
+
console.log('Fallback keys:', Object.keys(fallback));
|
|
26
|
+
|
|
27
|
+
console.log('Tests completed.');
|