potatejs 1.0.0-beta.0 → 1.0.0-beta.2
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/README.md +10 -10
- package/bin/potate-cli.mjs +1 -1
- package/dist/astro-client.js +1 -1
- package/dist/astro-integration.js +2 -24
- package/dist/astro-render.js +2 -1
- package/dist/chunk-FHGMMCU2.js +2 -0
- package/dist/chunk-J5LFFBK5.js +2 -0
- package/dist/chunk-JGG3UNRW.js +25 -0
- package/dist/{index-esbuild.js → index-esbuild-jsx.js} +4 -4
- package/dist/{index-vite.js → index-vite-jsx.js} +3 -3
- package/dist/index.js +4 -4
- package/dist/renderToString.js +1 -0
- package/dist/vite-integration.js +87 -0
- package/package.json +11 -9
- package/dist/ssr-vite.js +0 -1
package/README.md
CHANGED
|
@@ -19,6 +19,11 @@ Potate supports all the APIs of React including the upcoming concurrent mode API
|
|
|
19
19
|
- Fast alternative to Virtual DOM. (JSX without VDOM).
|
|
20
20
|
- Smaller transpiled footprint of your source code, than traditional JSX.
|
|
21
21
|
|
|
22
|
+
## LIVE DEMO with Astro
|
|
23
|
+
|
|
24
|
+
[Here](https://stackblitz.com/edit/github-cywxrcwm-3n79zz3t?file=src%2Fcomponents%2FPotate.jsx
|
|
25
|
+
) is a live demo with Astro on StackBlitz.
|
|
26
|
+
|
|
22
27
|
## Installation
|
|
23
28
|
|
|
24
29
|
### Astro
|
|
@@ -60,12 +65,6 @@ Now, you can use not only Astro components (`.astro`) but also Potate JSX compon
|
|
|
60
65
|
> * `client:load`(and others like `client:visible` or `client:idle`) **(SSR Hydration)**: Despite its cool and flashy name, "SSR Hydration" is not that complicated: it just creates a static HTML skeleton first, and once the JS is ready, the engine takes over the DOM as if it had been there from the start. If you are particular about the visual transition—like ensuring there is no layout shift by pre-setting an image's height—you might want to take control to make the swap feel completely natural.
|
|
61
66
|
|
|
62
67
|
|
|
63
|
-
#### LIVE DEMO with Astro
|
|
64
|
-
|
|
65
|
-
[Here](https://stackblitz.com/edit/github-cywxrcwm-3n79zz3t?file=src%2Fcomponents%2FPotate.jsx
|
|
66
|
-
) is a live demo with Astro on StackBlitz.
|
|
67
|
-
|
|
68
|
-
|
|
69
68
|
### Vite
|
|
70
69
|
|
|
71
70
|
Create your new app with `select a framework: > Vanilla`.
|
|
@@ -304,10 +303,11 @@ For the above example, the Brahmos output is 685 bytes, compared to 824 bytes fr
|
|
|
304
303
|
- [x] React Utilities and Methods
|
|
305
304
|
- [x] ⭐⭐⭐ Vite Plugin to transpile JSX to tagged templates
|
|
306
305
|
- [x] ⭐⭐⭐ Esbuild Plugin to transpile JSX to tagged templates
|
|
307
|
-
- [x] ⭐⭐⭐ [Potate Native Component(PNC)](docs/POTATE_NATIVE_COMPONENT.md)
|
|
308
|
-
- [x] ⭐⭐⭐ [SSR Emotion for Astro](docs/SSR_EMOTION_FOR_ASTRO.md)
|
|
309
|
-
- [x] ⭐⭐⭐ [
|
|
310
|
-
- [x] ⭐⭐⭐ [
|
|
306
|
+
- [x] ⭐⭐⭐ [Potate Native Component(PNC)](/docs/POTATE_NATIVE_COMPONENT.md)
|
|
307
|
+
- [x] ⭐⭐⭐ [SSR Emotion for Astro](/docs/SSR_EMOTION_FOR_ASTRO.md)
|
|
308
|
+
- [x] ⭐⭐⭐ [SSR Emotion for Vite](/docs/SSR_EMOTION_FOR_VITE.md)
|
|
309
|
+
- [x] ⭐⭐⭐ [reacty(ReactComponent) API](/docs/API.md)
|
|
310
|
+
- [x] ⭐⭐⭐ [watch(resource) API](/docs/API.md)
|
|
311
311
|
- [x] ⭐ The Lanes Light **(Though I haven't cleaned up the no-longer-needed TRANSITION_STATE_TIMED_OUT yet.)**
|
|
312
312
|
- [x] ⭐ The Standalone `startTransition`
|
|
313
313
|
- [x] ⭐ Enhanced `useTransition` hook
|
package/bin/potate-cli.mjs
CHANGED
package/dist/astro-client.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
import{createElement as
|
|
1
|
+
import{createElement as l,render as n}from"potatejs";var m=r=>(t,c,o,{client:d})=>{let e=document.createElement("div");n(l(t,c),e),r.replaceChildren(...Array.from(e.childNodes))};export{m as default};
|