mulguard 1.2.3 → 1.2.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 (3) hide show
  1. package/LICENSE +70 -0
  2. package/README.md +51 -0
  3. package/package.json +13 -14
package/LICENSE ADDED
@@ -0,0 +1,70 @@
1
+
2
+ ---
3
+
4
+ **Mulverse M.U.V GENERAL PUBLIC LICENSE**
5
+
6
+ **Version 1.0**
7
+
8
+ **Copyright (C) [2022] Mulverse Inc.**
9
+
10
+ **1. Definitions**
11
+
12
+ 1.1 **"Software"** refers to the Mulverse software distributed under this license, including all associated files, documentation, and any updates or modifications.
13
+
14
+ 1.2 **"You"** means the individual or entity who receives or uses the Software.
15
+
16
+ 1.3 **"Distribution"** refers to any form of sharing or redistribution of the Software, including copies or derivative works.
17
+
18
+ **2. Permissions**
19
+
20
+ 2.1 **Use**: You are granted the right to use the Software for any purpose.
21
+
22
+ 2.2 **Copy and Distribution**: You may distribute copies of the Software, either in its original form or as modified, provided that all copies include the same license terms.
23
+
24
+ 2.3 **Modification**: You may modify the Software and distribute the modified versions, provided that the modified Software is also licensed under this Mulverse M.U.V General Public License and that you include a prominent notice stating the changes made.
25
+
26
+ **3. Copyleft**
27
+
28
+ 3.1 **Source Code**: If you distribute the Software or any derivative works, you must either include the source code or make it available in a manner specified by this license.
29
+
30
+ 3.2 **License Continuity**: All copies and derivative works of the Software must be distributed under the terms of this Mulverse M.U.V General Public License. You must include a copy of this license with all distributions.
31
+
32
+ **4. Conditions**
33
+
34
+ 4.1 **Attribution**: You must provide appropriate credit to Mulverse Inc., including a notice that the Software is licensed under the Mulverse M.U.V General Public License.
35
+
36
+ 4.2 **No Warranty**: The Software is provided "as is," without any warranty of any kind. Mulverse Inc. disclaims all warranties and conditions, including but not limited to implied warranties of merchantability and fitness for a particular purpose.
37
+
38
+ 4.3 **No Additional Restrictions**: You may not impose any additional restrictions on the rights granted by this license. This includes, but is not limited to, additional licenses or agreements.
39
+
40
+ **5. Termination**
41
+
42
+ 5.1 **Automatic Termination**: If you breach any of the terms of this license, your rights under this license will be terminated automatically.
43
+
44
+ 5.2 **Reinstatement**: You may be reinstated if you cure the breach and notify Mulverse Inc. of the cure within 30 days of the termination.
45
+
46
+ **6. Patent Grant**
47
+
48
+ 6.1 **Patent License**: You grant to Mulverse Inc. a non-exclusive, royalty-free license to any patents you may hold that are necessary to use the Software.
49
+
50
+ **7. Indemnity**
51
+
52
+ 7.1 **Indemnification**: You agree to indemnify and hold Mulverse Inc. harmless from any claims, damages, or liabilities arising from your use or distribution of the Software.
53
+
54
+ **8. Governing Law**
55
+
56
+ 8.1 **Jurisdiction**: This license shall be governed by and construed in accordance with the laws of [Your Jurisdiction].
57
+
58
+ **9. Miscellaneous**
59
+
60
+ 9.1 **Severability**: If any provision of this license is held to be invalid or unenforceable, the remaining provisions will remain in effect.
61
+
62
+ 9.2 **Entire Agreement**: This license constitutes the entire agreement between you and Mulverse Inc. regarding the Software and supersedes all prior agreements and understandings.
63
+
64
+ **10. Contact**
65
+
66
+ 10.1 **Inquiries**: For any questions or concerns regarding this license, please contact Mulverse Inc. at [Contact Information].
67
+
68
+ **End of License**
69
+
70
+ ---
package/README.md CHANGED
@@ -18,4 +18,55 @@
18
18
 
19
19
  ---
20
20
 
21
+ ## Installation
22
+
23
+ ### From npm (Recommended)
24
+
25
+ ```bash
26
+ npm install mulguard
27
+ # or
28
+ pnpm add mulguard
29
+ # or
30
+ yarn add mulguard
31
+ ```
32
+
33
+ ### From Source (Development)
34
+
35
+ If you're installing from the source code (monorepo), you need to use **pnpm** because the package uses `workspace:*` protocol:
36
+
37
+ ```bash
38
+ # Install pnpm if you don't have it
39
+ npm install -g pnpm
40
+
41
+ # From the monorepo root
42
+ pnpm install
43
+ ```
44
+
45
+ If you encounter the error `Unsupported URL Type "workspace:"` when using npm:
46
+
47
+ 1. **Use pnpm instead** (recommended):
48
+
49
+ ```bash
50
+ pnpm install
51
+ ```
52
+
53
+ 2. **Or fix the workspace protocol manually**:
54
+ ```bash
55
+ # From packages/mulguard directory
56
+ node scripts/fix-workspace.js
57
+ npm install
58
+ ```
59
+
60
+ ### Troubleshooting
61
+
62
+ **Error: `Unsupported URL Type "workspace:"`**
63
+
64
+ This error occurs when trying to install from source code using npm instead of pnpm. Solutions:
65
+
66
+ - **Option 1**: Use pnpm (recommended for monorepo development)
67
+ - **Option 2**: Install from npm registry (if the package is published)
68
+ - **Option 3**: Run the fix script: `node packages/mulguard/scripts/fix-workspace.js`
69
+
70
+ ---
71
+
21
72
  Check out the documentation at [mulverse.com](https://mulverse.com) or visit the [Mulverse Network](https://mulverse.com) for more information.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "mulguard",
3
- "version": "1.2.3",
3
+ "version": "1.2.4",
4
4
  "description": "Authentication for Next.js with Backend-First Architecture",
5
5
  "homepage": "https://mulverse.com/packages/mulguard",
6
6
  "repository": "https://github.com/mulverse/mulverse.git",
@@ -65,17 +65,6 @@
65
65
  "oidc",
66
66
  "mulguard"
67
67
  ],
68
- "scripts": {
69
- "build": "pnpm clean && pnpm providers && node ../../node_modules/.pnpm/typescript@5.2.2/node_modules/typescript/bin/tsc",
70
- "clean": "node -e \"const fs = require('fs'); const path = require('path'); ['*.js', '*.d.ts*', 'lib', 'providers'].forEach(p => { try { if (fs.existsSync(p)) fs.rmSync(p, {recursive: true, force: true}); } catch(e) {} });\"",
71
- "dev": "pnpm providers && tsc -w",
72
- "test": "vitest run -c ../utils/vitest.config.ts",
73
- "test:watch": "vitest -c ../utils/vitest.config.ts",
74
- "test:e2e": "playwright test",
75
- "providers": "node ../utils/scripts/providers",
76
- "prepack": "node scripts/prepack.js",
77
- "postpack": "node scripts/postpack.js"
78
- },
79
68
  "files": [
80
69
  "*.d.ts*",
81
70
  "*.js",
@@ -88,7 +77,7 @@
88
77
  "access": "public"
89
78
  },
90
79
  "dependencies": {
91
- "@mulverse/mulguard-core": "^1.0.4"
80
+ "@mulverse/mulguard-core": "^1.0.5"
92
81
  },
93
82
  "peerDependencies": {
94
83
  "@simplewebauthn/browser": "^9.0.1",
@@ -115,5 +104,15 @@
115
104
  "nodemailer": "^7.0.7",
116
105
  "react": "^18.2.0",
117
106
  "typescript": "5.3.3"
107
+ },
108
+ "scripts": {
109
+ "build": "pnpm clean && pnpm providers && node ../../node_modules/.pnpm/typescript@5.2.2/node_modules/typescript/bin/tsc",
110
+ "clean": "node -e \"const fs = require('fs'); const path = require('path'); ['*.js', '*.d.ts*', 'lib', 'providers'].forEach(p => { try { if (fs.existsSync(p)) fs.rmSync(p, {recursive: true, force: true}); } catch(e) {} });\"",
111
+ "dev": "pnpm providers && tsc -w",
112
+ "test": "vitest run -c ../utils/vitest.config.ts",
113
+ "test:watch": "vitest -c ../utils/vitest.config.ts",
114
+ "test:e2e": "playwright test",
115
+ "providers": "node ../utils/scripts/providers",
116
+ "preinstall": "node scripts/preinstall.js"
118
117
  }
119
- }
118
+ }