rari 0.12.0 → 0.12.1
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.
|
@@ -1 +1 @@
|
|
|
1
|
-
function e(){return globalThis}function t(e){return{specifier:e.id,name:e.name||`default`}}function n(t){let n=e()[`~clientComponents`];if(!n)return null;let r=`${t.specifier}#${t.name}`,i=r.replace(/\\/g,`/`),a=t.specifier.replace(/\\/g,`/`),o=n[i]||n[r]||(t.name===`default`?n[a]||n[t.specifier]:void 0);return!o||o.component?null:o.loadPromise?o.loadPromise:o.loader?(o.loading=!0,o.loadPromise=o.loader().then(e=>(o.component=e,o.registered=!0,o.loading=!1,e)).catch(e=>{throw o.loading=!1,o.loadPromise=void 0,e}),o.loadPromise):null}function r(t){let n=e()[`~clientComponents`];if(!n)throw Error(`[rari] Client components registry not found`);let r=`${t.specifier}#${t.name}`,i=r.replace(/\\/g,`/`),a=t.specifier.replace(/\\/g,`/`),o=n[i]||n[r]||(t.name===`default`?n[a]||n[t.specifier]:void 0);if(!o)throw Error(`[rari] Component not registered: ${r}`);if(o.component){let e=o.component;return
|
|
1
|
+
function e(){return globalThis}function t(e){return{specifier:e.id,name:e.name||`default`}}function n(t){let n=e()[`~clientComponents`];if(!n)return null;let r=`${t.specifier}#${t.name}`,i=r.replace(/\\/g,`/`),a=t.specifier.replace(/\\/g,`/`),o=n[i]||n[r]||(t.name===`default`?n[a]||n[t.specifier]:void 0);return!o||o.component?null:o.loadPromise?o.loadPromise:o.loader?(o.loading=!0,o.loadPromise=o.loader().then(e=>(o.component=e,o.registered=!0,o.loading=!1,e)).catch(e=>{throw o.loading=!1,o.loadPromise=void 0,e}),o.loadPromise):null}function r(t){let n=e()[`~clientComponents`];if(!n)throw Error(`[rari] Client components registry not found`);let r=`${t.specifier}#${t.name}`,i=r.replace(/\\/g,`/`),a=t.specifier.replace(/\\/g,`/`),o=n[i]||n[r]||(t.name===`default`?n[a]||n[t.specifier]:void 0);if(!o)throw Error(`[rari] Component not registered: ${r}`);if(o.component){let e=o.component;return t.name===`default`?e.default??e:e[t.name]===void 0?e.default?.[t.name]===void 0?e:e.default[t.name]:e[t.name]}throw o.loadPromise?o.loadPromise:o.loader?(o.loading=!0,o.loadPromise=o.loader().then(e=>(o.component=e,o.registered=!0,o.loading=!1,e)).catch(e=>{throw o.loading=!1,o.loadPromise=void 0,e}),o.loadPromise):Error(`[rari] Module not found: ${r}`)}function i(e,t){return e.decode(t,{stream:!0})}function a(e,t){return e.decode(t)}function o(){return new TextDecoder}export{o as createStringDecoder,n as preloadModule,a as readFinalStringChunk,i as readPartialStringChunk,r as requireModule,t as resolveClientReference};
|
package/dist/vite.mjs
CHANGED
|
@@ -46,25 +46,25 @@ const ${t} = registerClientReference(
|
|
|
46
46
|
path: "${r}",
|
|
47
47
|
exportName: "${o}",
|
|
48
48
|
type: "client",
|
|
49
|
-
loader: () => ${
|
|
49
|
+
loader: () => ${`import(${JSON.stringify(c)})`},
|
|
50
50
|
component: null,
|
|
51
51
|
loading: false,
|
|
52
52
|
registered: false
|
|
53
53
|
}`}).join(`,
|
|
54
|
-
`),a=r.map((e,t)=>`import
|
|
55
|
-
`),s=r.flatMap((e,t)=>e.exports.map(n
|
|
54
|
+
`),a=r.map((e,t)=>`import * as ExternalModule${t} from '${e.path}';`).join(`
|
|
55
|
+
`),s=r.flatMap((e,t)=>e.exports.map(n=>`
|
|
56
56
|
globalThis['~clientComponents'] = globalThis['~clientComponents'] || {};
|
|
57
57
|
globalThis['~clientComponents']["${`${e.path}#${n}`}"] = {
|
|
58
58
|
id: "${n}",
|
|
59
59
|
path: "${e.path}",
|
|
60
60
|
type: "client",
|
|
61
|
-
component: ${
|
|
61
|
+
component: ExternalModule${t},
|
|
62
62
|
registered: true
|
|
63
63
|
};
|
|
64
64
|
globalThis['~clientComponents']["${e.path}"] = globalThis['~clientComponents']["${e.path}"] || {};
|
|
65
|
-
globalThis['~clientComponents']["${e.path}"].component = ${
|
|
65
|
+
globalThis['~clientComponents']["${e.path}"].component = ExternalModule${t};
|
|
66
66
|
globalThis['~clientComponentPaths'] = globalThis['~clientComponentPaths'] || {};
|
|
67
|
-
globalThis['~clientComponentPaths']["${e.path}"] = "${n}";`
|
|
67
|
+
globalThis['~clientComponentPaths']["${e.path}"] = "${n}";`)).join(`
|
|
68
68
|
`);return await pt(a,[`
|
|
69
69
|
const lazyComponentRegistry = {
|
|
70
70
|
${i}
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "rari",
|
|
3
3
|
"type": "module",
|
|
4
|
-
"version": "0.12.
|
|
4
|
+
"version": "0.12.1",
|
|
5
5
|
"description": "Runtime Accelerated Rendering Infrastructure (rari)",
|
|
6
6
|
"author": "Ryan Skinner",
|
|
7
7
|
"license": "MIT",
|
|
@@ -107,23 +107,23 @@
|
|
|
107
107
|
"react-dom": "^19.2.4"
|
|
108
108
|
},
|
|
109
109
|
"dependencies": {
|
|
110
|
-
"rolldown": "^1.0.0-rc.
|
|
110
|
+
"rolldown": "^1.0.0-rc.16"
|
|
111
111
|
},
|
|
112
112
|
"optionalDependencies": {
|
|
113
|
-
"rari-darwin-arm64": "0.12.
|
|
114
|
-
"rari-darwin-x64": "0.12.
|
|
115
|
-
"rari-linux-arm64": "0.12.
|
|
116
|
-
"rari-linux-x64": "0.12.
|
|
117
|
-
"rari-win32-x64": "0.12.
|
|
113
|
+
"rari-darwin-arm64": "0.12.1",
|
|
114
|
+
"rari-darwin-x64": "0.12.1",
|
|
115
|
+
"rari-linux-arm64": "0.12.1",
|
|
116
|
+
"rari-linux-x64": "0.12.1",
|
|
117
|
+
"rari-win32-x64": "0.12.1"
|
|
118
118
|
},
|
|
119
119
|
"devDependencies": {
|
|
120
120
|
"@types/node": "^25.6.0",
|
|
121
121
|
"@types/react": "^19.2.14",
|
|
122
122
|
"@types/react-dom": "^19.2.3",
|
|
123
|
-
"@typescript/native-preview": "^7.0.0-dev.
|
|
124
|
-
"vite-plus": "^0.1.
|
|
125
|
-
"@rari/
|
|
126
|
-
"@rari/
|
|
123
|
+
"@typescript/native-preview": "^7.0.0-dev.20260416.2",
|
|
124
|
+
"vite-plus": "^0.1.18",
|
|
125
|
+
"@rari/deploy": "0.1.0",
|
|
126
|
+
"@rari/logger": "0.1.0"
|
|
127
127
|
},
|
|
128
128
|
"scripts": {
|
|
129
129
|
"build": "pnpm clean && pnpm typecheck && vp pack",
|