litestar-vite 0.1.1__py3-none-any.whl → 0.15.0rc2__py3-none-any.whl
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.
- litestar_vite/__init__.py +54 -4
- litestar_vite/__metadata__.py +12 -7
- litestar_vite/_codegen/__init__.py +26 -0
- litestar_vite/_codegen/inertia.py +407 -0
- litestar_vite/_codegen/openapi.py +233 -0
- litestar_vite/_codegen/routes.py +653 -0
- litestar_vite/_codegen/ts.py +235 -0
- litestar_vite/_handler/__init__.py +8 -0
- litestar_vite/_handler/app.py +524 -0
- litestar_vite/_handler/routing.py +130 -0
- litestar_vite/cli.py +1147 -10
- litestar_vite/codegen.py +39 -0
- litestar_vite/commands.py +79 -0
- litestar_vite/config.py +1594 -70
- litestar_vite/deploy.py +355 -0
- litestar_vite/doctor.py +1179 -0
- litestar_vite/exceptions.py +78 -0
- litestar_vite/executor.py +316 -0
- litestar_vite/handler.py +9 -0
- litestar_vite/html_transform.py +426 -0
- litestar_vite/inertia/__init__.py +53 -0
- litestar_vite/inertia/_utils.py +114 -0
- litestar_vite/inertia/exception_handler.py +172 -0
- litestar_vite/inertia/helpers.py +1043 -0
- litestar_vite/inertia/middleware.py +54 -0
- litestar_vite/inertia/plugin.py +133 -0
- litestar_vite/inertia/request.py +286 -0
- litestar_vite/inertia/response.py +706 -0
- litestar_vite/inertia/types.py +316 -0
- litestar_vite/loader.py +462 -121
- litestar_vite/plugin.py +2160 -21
- litestar_vite/py.typed +0 -0
- litestar_vite/scaffolding/__init__.py +20 -0
- litestar_vite/scaffolding/generator.py +270 -0
- litestar_vite/scaffolding/templates.py +437 -0
- litestar_vite/templates/__init__.py +0 -0
- litestar_vite/templates/addons/tailwindcss/tailwind.css.j2 +1 -0
- litestar_vite/templates/angular/index.html.j2 +12 -0
- litestar_vite/templates/angular/openapi-ts.config.ts.j2 +18 -0
- litestar_vite/templates/angular/package.json.j2 +35 -0
- litestar_vite/templates/angular/src/app/app.component.css.j2 +3 -0
- litestar_vite/templates/angular/src/app/app.component.html.j2 +1 -0
- litestar_vite/templates/angular/src/app/app.component.ts.j2 +9 -0
- litestar_vite/templates/angular/src/app/app.config.ts.j2 +5 -0
- litestar_vite/templates/angular/src/main.ts.j2 +9 -0
- litestar_vite/templates/angular/src/styles.css.j2 +9 -0
- litestar_vite/templates/angular/tsconfig.app.json.j2 +34 -0
- litestar_vite/templates/angular/tsconfig.json.j2 +20 -0
- litestar_vite/templates/angular/vite.config.ts.j2 +21 -0
- litestar_vite/templates/angular-cli/.postcssrc.json.j2 +5 -0
- litestar_vite/templates/angular-cli/angular.json.j2 +36 -0
- litestar_vite/templates/angular-cli/openapi-ts.config.ts.j2 +18 -0
- litestar_vite/templates/angular-cli/package.json.j2 +27 -0
- litestar_vite/templates/angular-cli/proxy.conf.json.j2 +18 -0
- litestar_vite/templates/angular-cli/src/app/app.component.css.j2 +3 -0
- litestar_vite/templates/angular-cli/src/app/app.component.html.j2 +1 -0
- litestar_vite/templates/angular-cli/src/app/app.component.ts.j2 +9 -0
- litestar_vite/templates/angular-cli/src/app/app.config.ts.j2 +5 -0
- litestar_vite/templates/angular-cli/src/index.html.j2 +13 -0
- litestar_vite/templates/angular-cli/src/main.ts.j2 +6 -0
- litestar_vite/templates/angular-cli/src/styles.css.j2 +10 -0
- litestar_vite/templates/angular-cli/tailwind.config.js.j2 +4 -0
- litestar_vite/templates/angular-cli/tsconfig.app.json.j2 +16 -0
- litestar_vite/templates/angular-cli/tsconfig.json.j2 +26 -0
- litestar_vite/templates/angular-cli/tsconfig.spec.json.j2 +9 -0
- litestar_vite/templates/astro/astro.config.mjs.j2 +28 -0
- litestar_vite/templates/astro/openapi-ts.config.ts.j2 +15 -0
- litestar_vite/templates/astro/src/layouts/Layout.astro.j2 +63 -0
- litestar_vite/templates/astro/src/pages/index.astro.j2 +36 -0
- litestar_vite/templates/astro/src/styles/global.css.j2 +1 -0
- litestar_vite/templates/base/.gitignore.j2 +42 -0
- litestar_vite/templates/base/openapi-ts.config.ts.j2 +15 -0
- litestar_vite/templates/base/package.json.j2 +38 -0
- litestar_vite/templates/base/resources/vite-env.d.ts.j2 +1 -0
- litestar_vite/templates/base/tsconfig.json.j2 +37 -0
- litestar_vite/templates/htmx/src/main.js.j2 +8 -0
- litestar_vite/templates/htmx/templates/base.html.j2.j2 +56 -0
- litestar_vite/templates/htmx/templates/index.html.j2.j2 +13 -0
- litestar_vite/templates/htmx/vite.config.ts.j2 +40 -0
- litestar_vite/templates/nuxt/app.vue.j2 +29 -0
- litestar_vite/templates/nuxt/composables/useApi.ts.j2 +33 -0
- litestar_vite/templates/nuxt/nuxt.config.ts.j2 +31 -0
- litestar_vite/templates/nuxt/openapi-ts.config.ts.j2 +15 -0
- litestar_vite/templates/nuxt/pages/index.vue.j2 +54 -0
- litestar_vite/templates/react/index.html.j2 +13 -0
- litestar_vite/templates/react/src/App.css.j2 +56 -0
- litestar_vite/templates/react/src/App.tsx.j2 +19 -0
- litestar_vite/templates/react/src/main.tsx.j2 +10 -0
- litestar_vite/templates/react/vite.config.ts.j2 +39 -0
- litestar_vite/templates/react-inertia/index.html.j2 +14 -0
- litestar_vite/templates/react-inertia/package.json.j2 +46 -0
- litestar_vite/templates/react-inertia/resources/App.css.j2 +68 -0
- litestar_vite/templates/react-inertia/resources/main.tsx.j2 +17 -0
- litestar_vite/templates/react-inertia/resources/pages/Home.tsx.j2 +18 -0
- litestar_vite/templates/react-inertia/resources/ssr.tsx.j2 +19 -0
- litestar_vite/templates/react-inertia/vite.config.ts.j2 +59 -0
- litestar_vite/templates/react-router/index.html.j2 +12 -0
- litestar_vite/templates/react-router/src/App.css.j2 +17 -0
- litestar_vite/templates/react-router/src/App.tsx.j2 +7 -0
- litestar_vite/templates/react-router/src/main.tsx.j2 +10 -0
- litestar_vite/templates/react-router/vite.config.ts.j2 +39 -0
- litestar_vite/templates/react-tanstack/index.html.j2 +12 -0
- litestar_vite/templates/react-tanstack/openapi-ts.config.ts.j2 +18 -0
- litestar_vite/templates/react-tanstack/src/App.css.j2 +17 -0
- litestar_vite/templates/react-tanstack/src/main.tsx.j2 +21 -0
- litestar_vite/templates/react-tanstack/src/routeTree.gen.ts.j2 +7 -0
- litestar_vite/templates/react-tanstack/src/routes/__root.tsx.j2 +9 -0
- litestar_vite/templates/react-tanstack/src/routes/books.tsx.j2 +9 -0
- litestar_vite/templates/react-tanstack/src/routes/index.tsx.j2 +9 -0
- litestar_vite/templates/react-tanstack/vite.config.ts.j2 +39 -0
- litestar_vite/templates/svelte/index.html.j2 +13 -0
- litestar_vite/templates/svelte/src/App.svelte.j2 +30 -0
- litestar_vite/templates/svelte/src/app.css.j2 +45 -0
- litestar_vite/templates/svelte/src/main.ts.j2 +8 -0
- litestar_vite/templates/svelte/src/vite-env.d.ts.j2 +2 -0
- litestar_vite/templates/svelte/svelte.config.js.j2 +5 -0
- litestar_vite/templates/svelte/vite.config.ts.j2 +39 -0
- litestar_vite/templates/svelte-inertia/index.html.j2 +14 -0
- litestar_vite/templates/svelte-inertia/resources/app.css.j2 +21 -0
- litestar_vite/templates/svelte-inertia/resources/main.ts.j2 +11 -0
- litestar_vite/templates/svelte-inertia/resources/pages/Home.svelte.j2 +43 -0
- litestar_vite/templates/svelte-inertia/resources/vite-env.d.ts.j2 +2 -0
- litestar_vite/templates/svelte-inertia/svelte.config.js.j2 +5 -0
- litestar_vite/templates/svelte-inertia/vite.config.ts.j2 +37 -0
- litestar_vite/templates/sveltekit/openapi-ts.config.ts.j2 +15 -0
- litestar_vite/templates/sveltekit/src/app.css.j2 +40 -0
- litestar_vite/templates/sveltekit/src/app.html.j2 +12 -0
- litestar_vite/templates/sveltekit/src/hooks.server.ts.j2 +55 -0
- litestar_vite/templates/sveltekit/src/routes/+layout.svelte.j2 +12 -0
- litestar_vite/templates/sveltekit/src/routes/+page.svelte.j2 +34 -0
- litestar_vite/templates/sveltekit/svelte.config.js.j2 +12 -0
- litestar_vite/templates/sveltekit/tsconfig.json.j2 +14 -0
- litestar_vite/templates/sveltekit/vite.config.ts.j2 +31 -0
- litestar_vite/templates/vue/env.d.ts.j2 +7 -0
- litestar_vite/templates/vue/index.html.j2 +13 -0
- litestar_vite/templates/vue/src/App.vue.j2 +28 -0
- litestar_vite/templates/vue/src/main.ts.j2 +5 -0
- litestar_vite/templates/vue/src/style.css.j2 +45 -0
- litestar_vite/templates/vue/vite.config.ts.j2 +39 -0
- litestar_vite/templates/vue-inertia/env.d.ts.j2 +7 -0
- litestar_vite/templates/vue-inertia/index.html.j2 +14 -0
- litestar_vite/templates/vue-inertia/package.json.j2 +49 -0
- litestar_vite/templates/vue-inertia/resources/main.ts.j2 +18 -0
- litestar_vite/templates/vue-inertia/resources/pages/Home.vue.j2 +22 -0
- litestar_vite/templates/vue-inertia/resources/ssr.ts.j2 +21 -0
- litestar_vite/templates/vue-inertia/resources/style.css.j2 +21 -0
- litestar_vite/templates/vue-inertia/vite.config.ts.j2 +59 -0
- litestar_vite-0.15.0rc2.dist-info/METADATA +230 -0
- litestar_vite-0.15.0rc2.dist-info/RECORD +151 -0
- {litestar_vite-0.1.1.dist-info → litestar_vite-0.15.0rc2.dist-info}/WHEEL +1 -1
- litestar_vite/template_engine.py +0 -103
- litestar_vite-0.1.1.dist-info/METADATA +0 -68
- litestar_vite-0.1.1.dist-info/RECORD +0 -11
- {litestar_vite-0.1.1.dist-info → litestar_vite-0.15.0rc2.dist-info}/licenses/LICENSE +0 -0
|
@@ -0,0 +1,151 @@
|
|
|
1
|
+
litestar_vite/__init__.py,sha256=6z2O7JKG-PplQmFczzTyW862wkOrW4M_xm1VI47bHHM,1421
|
|
2
|
+
litestar_vite/__metadata__.py,sha256=dMGIPS6M11LcmiEfnMJJrbSPH8Lf00pU8crIIUsIBPw,478
|
|
3
|
+
litestar_vite/cli.py,sha256=3ido1_BmM03OYvrEhHo23lXaxLrr2bDvA79FkAI8LBA,43701
|
|
4
|
+
litestar_vite/codegen.py,sha256=4v_I3wsJOTlSpPxNsM4gxEFRpixK7qI6n-8EGjUTnDg,1331
|
|
5
|
+
litestar_vite/commands.py,sha256=83ZZH5FaXhMwmomjr-4DaCkdEb9c5JFLGvzWpx7hP18,2643
|
|
6
|
+
litestar_vite/config.py,sha256=XkDv254B_INxY7fuXwCfBBwAGda_p2La6WJBo8MaLyo,59327
|
|
7
|
+
litestar_vite/deploy.py,sha256=WuGpnWrrZs6YXBRViYTZujVVN5WPUY-HZl2jo4-Mk7I,11828
|
|
8
|
+
litestar_vite/doctor.py,sha256=lAVgBCXzgNflTgmeeIs0kJOJMne1xG0VAQi9rxmE_Ws,47174
|
|
9
|
+
litestar_vite/exceptions.py,sha256=9PfOfC1eLxY3ZmMBCxv1NLAbkREMz5BZzpPgVbgYfTA,2651
|
|
10
|
+
litestar_vite/executor.py,sha256=F9FXtEROztEYdT7nAkJmTgz84SLPwkgsB8KaFp3hm80,10696
|
|
11
|
+
litestar_vite/handler.py,sha256=2yHNyJBkffXA1xp-CsyNEGRiTymCX8To6-jq5OrGo0w,255
|
|
12
|
+
litestar_vite/html_transform.py,sha256=20aY0VsOX5zL9F2g_ba5Q7yRtfTt4Cf4s2XmTVbumFw,14924
|
|
13
|
+
litestar_vite/loader.py,sha256=69LKn3pc7qw5eBlkFA72pDybobwt5KSNkr-GDzk8DfU,18537
|
|
14
|
+
litestar_vite/plugin.py,sha256=iI-k5kq8QRMhMBnrIMY7siCdHdNi3HVd1UKySDtZsio,82594
|
|
15
|
+
litestar_vite/py.typed,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
16
|
+
litestar_vite/_codegen/__init__.py,sha256=vFFcB-o0xoA6SkHgpoAM3Ji5e0gVoGAVPEjNq6Xf_5Y,780
|
|
17
|
+
litestar_vite/_codegen/inertia.py,sha256=pqI8xYGZL0hqFgp8luwn8uwwK3nhhE_b8ISo6PJO11Y,14261
|
|
18
|
+
litestar_vite/_codegen/openapi.py,sha256=Qvema_LiwUSBiOlbAVY-pDp8Mf1N_Y0Lz1WvotpnUDg,8293
|
|
19
|
+
litestar_vite/_codegen/routes.py,sha256=Z_oDyW1pxoQPq2yZZJo3C8rUhQz16DLWsoWK2s6yG5Y,22107
|
|
20
|
+
litestar_vite/_codegen/ts.py,sha256=ry9EvJr3P1yzxFxUwYM5gWTxx38QtyUmpI-Gh7gSneM,7960
|
|
21
|
+
litestar_vite/_handler/__init__.py,sha256=u-c7J29UI0YIFhzVW3w2dnHe2QgIOi36FE4Qcu-FE-w,183
|
|
22
|
+
litestar_vite/_handler/app.py,sha256=rlWWz59gqVlZdnRmUmVvWDYFy5Xm8rwswya21qvLxow,19748
|
|
23
|
+
litestar_vite/_handler/routing.py,sha256=rHO7zsWOtFgQ1-A02BGh-QU3vEvze9MvUGIqPiF8jTs,4540
|
|
24
|
+
litestar_vite/inertia/__init__.py,sha256=6SxGfPufyCo1Mp9ZRCe02XxdlY7i17l3visWklfW6pw,1364
|
|
25
|
+
litestar_vite/inertia/_utils.py,sha256=IkbqtPVyiJ_9k33Ff9ZgRpGz1MnuovzrQdPfD4Yw18k,2948
|
|
26
|
+
litestar_vite/inertia/exception_handler.py,sha256=uRRs_oRwQFByhRoE5Kc0A0lizjERgFktUmVu5aekBw8,7356
|
|
27
|
+
litestar_vite/inertia/helpers.py,sha256=dwbftJW_HofR6uVwm6XUV-7JnZPKRWuplaQD11BejM8,34852
|
|
28
|
+
litestar_vite/inertia/middleware.py,sha256=GIwOl_KZyI6KAJ2VY4aK_WZiPM1F_LSgdH3yRFgkm1M,1998
|
|
29
|
+
litestar_vite/inertia/plugin.py,sha256=a4tRdiwrXPKXPa5Fv-pJ0oCwcvFibqh0uONLmZu1uNI,5179
|
|
30
|
+
litestar_vite/inertia/request.py,sha256=1UEra90zmP4XeN82wT92hRQ7FBRKOLRBQRoStDNt_iw,9196
|
|
31
|
+
litestar_vite/inertia/response.py,sha256=qeYCuIziiWoQOuxogXAqcAZMKR_zaLBnAk0QXuDIRLY,29771
|
|
32
|
+
litestar_vite/inertia/types.py,sha256=PHDh8b8SuWliTzFjWns9h8551qPzBmYW5hnmPDI6Syg,9902
|
|
33
|
+
litestar_vite/scaffolding/__init__.py,sha256=3MkLZtAjyZYHh7THWYZF5HFsxXHHT9t3_pcF8zwL07g,652
|
|
34
|
+
litestar_vite/scaffolding/generator.py,sha256=Y1PPT1-u-ujgaJ4aD43IdcnI_hal75HjsdOINNeCm8w,9172
|
|
35
|
+
litestar_vite/scaffolding/templates.py,sha256=kX2jNmmddy48YqYQFdcMcWBaAo3IbGzEDcTYAgyVzcs,14371
|
|
36
|
+
litestar_vite/templates/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
37
|
+
litestar_vite/templates/addons/tailwindcss/tailwind.css.j2,sha256=QgcOC0W7IBsrg4pSqqpull-WTgtULZfx_lF_5ZxLdag,23
|
|
38
|
+
litestar_vite/templates/angular/index.html.j2,sha256=lEnI1yFMq2BGK_cxnHwFnhx6rfHbsdFzdid0clsJM1o,319
|
|
39
|
+
litestar_vite/templates/angular/openapi-ts.config.ts.j2,sha256=bsnHZ9GiNk98_BK1V0G02cNHUHwtbgINzWr0zuu3mHg,400
|
|
40
|
+
litestar_vite/templates/angular/package.json.j2,sha256=vRzZXTXRD96bFpArIGL4C6OSwCt6J8q2DBv6OoIeAo0,845
|
|
41
|
+
litestar_vite/templates/angular/tsconfig.app.json.j2,sha256=O1STsrXFeL-TM1z4zv7l38hGK3LgV7wtflN2zfdb_V4,988
|
|
42
|
+
litestar_vite/templates/angular/tsconfig.json.j2,sha256=aB2V5FFJXYvJWHccnLTcxjYr8aH6Ffxc0dVqOPueBZI,491
|
|
43
|
+
litestar_vite/templates/angular/vite.config.ts.j2,sha256=7mN399dErmChKLhRDXovHBMuTaagyu6Am8PUoneyhGY,600
|
|
44
|
+
litestar_vite/templates/angular/src/main.ts.j2,sha256=GoGPeumY5SN3DZj7pbD3ct8_d6V5pVlc_-1Sk5Y7ips,327
|
|
45
|
+
litestar_vite/templates/angular/src/styles.css.j2,sha256=ok41iiQlpVywb0lohl0x1HVAiPq19PX_6u8pEPDZvxM,242
|
|
46
|
+
litestar_vite/templates/angular/src/app/app.component.css.j2,sha256=7CyJ_ekTyv90G6oLDzz2iprLXoVGfk8htsgk_a0gE5Q,28
|
|
47
|
+
litestar_vite/templates/angular/src/app/app.component.html.j2,sha256=JtDZXjjOC8_g1GDMGiN8GCxkki8rGnfS2g_HpRD5RXs,14
|
|
48
|
+
litestar_vite/templates/angular/src/app/app.component.ts.j2,sha256=SGbzdLsv_bijTbt6vCGF5rBLx4s3vixX-P9IB8GmAK8,207
|
|
49
|
+
litestar_vite/templates/angular/src/app/app.config.ts.j2,sha256=vSMNCRyDqIIjIHUTZoa6mhjW1PrEeeKjpEkqrZtsFRA,123
|
|
50
|
+
litestar_vite/templates/angular-cli/.postcssrc.json.j2,sha256=bJanvszoCUi1KJeoloqBVkTXDb5kcieuYnqcyg7curs,54
|
|
51
|
+
litestar_vite/templates/angular-cli/angular.json.j2,sha256=XboCBhSihwkpQjbowuUJPqjfbQ3U2tP_3qg9AHnZ5pw,1092
|
|
52
|
+
litestar_vite/templates/angular-cli/openapi-ts.config.ts.j2,sha256=bsnHZ9GiNk98_BK1V0G02cNHUHwtbgINzWr0zuu3mHg,400
|
|
53
|
+
litestar_vite/templates/angular-cli/package.json.j2,sha256=mxQoc0nJWB2SRIJQ9Y5IzVmCzYRhUN1McXX6c70pdQ0,642
|
|
54
|
+
litestar_vite/templates/angular-cli/proxy.conf.json.j2,sha256=63K860aZoEizF4BsL-dUjguko0VfsNRdVvjQ3wG1b94,337
|
|
55
|
+
litestar_vite/templates/angular-cli/tailwind.config.js.j2,sha256=uZ_nSmbT7e4kVeX5IggRM_q10ZLRPaqk0aypUOubdbE,100
|
|
56
|
+
litestar_vite/templates/angular-cli/tsconfig.app.json.j2,sha256=oNNNykaLX3mVSnzreqTm1HeUyH6O5qKb4mBMBNULJc0,416
|
|
57
|
+
litestar_vite/templates/angular-cli/tsconfig.json.j2,sha256=T2mVozneR2j34lBHB-pkpJ22CSEoN7f3lNmgYFJ9u9g,716
|
|
58
|
+
litestar_vite/templates/angular-cli/tsconfig.spec.json.j2,sha256=Vt3nU6jZ_u1L8QELTX8KDwl4tVduRJ6S-EEd_BjXq-g,192
|
|
59
|
+
litestar_vite/templates/angular-cli/src/index.html.j2,sha256=1MUNk69gJtKhc4hb3jSWiQaay7V6fZ66ACfvbLRJRhI,332
|
|
60
|
+
litestar_vite/templates/angular-cli/src/main.ts.j2,sha256=71dZCa10Rw_gd3bbTkige2RFKGP5W7PIVjc4nUHvILY,248
|
|
61
|
+
litestar_vite/templates/angular-cli/src/styles.css.j2,sha256=JW-NAUrCgTYsijNRWhOeuMPyYp0QMk2QPptpGB6-h_g,243
|
|
62
|
+
litestar_vite/templates/angular-cli/src/app/app.component.css.j2,sha256=7CyJ_ekTyv90G6oLDzz2iprLXoVGfk8htsgk_a0gE5Q,28
|
|
63
|
+
litestar_vite/templates/angular-cli/src/app/app.component.html.j2,sha256=JtDZXjjOC8_g1GDMGiN8GCxkki8rGnfS2g_HpRD5RXs,14
|
|
64
|
+
litestar_vite/templates/angular-cli/src/app/app.component.ts.j2,sha256=SGbzdLsv_bijTbt6vCGF5rBLx4s3vixX-P9IB8GmAK8,207
|
|
65
|
+
litestar_vite/templates/angular-cli/src/app/app.config.ts.j2,sha256=vSMNCRyDqIIjIHUTZoa6mhjW1PrEeeKjpEkqrZtsFRA,123
|
|
66
|
+
litestar_vite/templates/astro/astro.config.mjs.j2,sha256=iV3C-g7vuJOhqeZ5CFXJQRArPFL59N-jgcctSOMDT7o,854
|
|
67
|
+
litestar_vite/templates/astro/openapi-ts.config.ts.j2,sha256=SLbesyZvl5tDPy-e3wR2tcPYcQI2Osq21S8G5zS_T5w,356
|
|
68
|
+
litestar_vite/templates/astro/src/layouts/Layout.astro.j2,sha256=fBwznyNapGZJgcGHBLmLvMjxuPsZ5ssPU_Ooae2oXJw,1252
|
|
69
|
+
litestar_vite/templates/astro/src/pages/index.astro.j2,sha256=f8zErww-qoLHLxR7g5Ac7YFlx6LJJ2WrXyVQU56ICMw,626
|
|
70
|
+
litestar_vite/templates/astro/src/styles/global.css.j2,sha256=oxYbL_6aNdNc9gc0BKFQdxZ0ZYxbtyiuf7k-1O0KnLA,49
|
|
71
|
+
litestar_vite/templates/base/.gitignore.j2,sha256=NeAMLX5IAWbNw_HlBma846zKEaQEVbQN-iO9akBuOKk,355
|
|
72
|
+
litestar_vite/templates/base/openapi-ts.config.ts.j2,sha256=tBS4wDuPZOtxXKiod7ZNi1v93uaATIEdd-UZ6H9TPVE,356
|
|
73
|
+
litestar_vite/templates/base/package.json.j2,sha256=gBvl8oGfSNf8mbLOsadR5gthob2UepReu2qgk9E_bE0,1096
|
|
74
|
+
litestar_vite/templates/base/tsconfig.json.j2,sha256=oLXhTh1ULIGka2aiTyyTRnRTzXgMyvPekPbBbH23VwU,1069
|
|
75
|
+
litestar_vite/templates/base/resources/vite-env.d.ts.j2,sha256=ZZlpNvuwQpFfe3SiAPzd5-QQ8ypmmxq5WXz6pLD63bU,38
|
|
76
|
+
litestar_vite/templates/htmx/vite.config.ts.j2,sha256=BVPMU1VADecUNIRbL2E9-9NLWvekak1aihyyVXr-U6g,865
|
|
77
|
+
litestar_vite/templates/htmx/src/main.js.j2,sha256=F0qsnUECff7SBdYSF4eM087H04XH3uzjYo701T1nXb4,176
|
|
78
|
+
litestar_vite/templates/htmx/templates/base.html.j2.j2,sha256=I8IUuSvADnKhyxbuTTMIDtCcLrVv2vIc8aoPAVCh6YU,1395
|
|
79
|
+
litestar_vite/templates/htmx/templates/index.html.j2.j2,sha256=Lx7i_pdR5UaEUGTWpxsxBCXaU1Ppm9ZBP1wJROP1Icc,367
|
|
80
|
+
litestar_vite/templates/nuxt/app.vue.j2,sha256=iiHHOzTsXiLau4o6al-W4fkubWNoFq4ImU47hUFZrKQ,551
|
|
81
|
+
litestar_vite/templates/nuxt/nuxt.config.ts.j2,sha256=uW6_4zt-DvYrSxVDyQIeNOlfe3aFzai4PhO_p3SJdJ8,982
|
|
82
|
+
litestar_vite/templates/nuxt/openapi-ts.config.ts.j2,sha256=ttFYDARQhtgZo5y1RPfJDm0n8GYsERKv8KtHs14K9hU,317
|
|
83
|
+
litestar_vite/templates/nuxt/composables/useApi.ts.j2,sha256=G6Oqi9VMzquLPwkDVV3IsljGpUV6OycdlS-l1tXdbzI,905
|
|
84
|
+
litestar_vite/templates/nuxt/pages/index.vue.j2,sha256=LxC7s_N-qXZhjdzW6-77_fGDxIbpVzJkEUvlnkOoCaA,851
|
|
85
|
+
litestar_vite/templates/react/index.html.j2,sha256=vJQk1SeeL8zj7eh_R5Z9hulPhVqGogiC9wys72vff_I,382
|
|
86
|
+
litestar_vite/templates/react/vite.config.ts.j2,sha256=4yoCesOaPcipOVV82AneKaBQHjz4rsBBD0PcKoTpDO0,811
|
|
87
|
+
litestar_vite/templates/react/src/App.css.j2,sha256=OxIIilAjaaZ9J5bhJ-bybunK6GgEaCootwYL-sdghrM,987
|
|
88
|
+
litestar_vite/templates/react/src/App.tsx.j2,sha256=eTMcZCisXmjPDTxlvl9mv0_mVmRaNS4ctfK07NjKgmM,392
|
|
89
|
+
litestar_vite/templates/react/src/main.tsx.j2,sha256=jn5402e-IPzroxfS25upeLPtvd8aJod_pGHaYUVWKDU,228
|
|
90
|
+
litestar_vite/templates/react-inertia/index.html.j2,sha256=UI0OvfKMFHwz7KNyLa9lxHGK3Dhrd-L6vtsiEu4PklM,449
|
|
91
|
+
litestar_vite/templates/react-inertia/package.json.j2,sha256=m9Ev8y1Yv-HaN0pEziOopT8R9SxoWnArUciLaQumduo,1306
|
|
92
|
+
litestar_vite/templates/react-inertia/vite.config.ts.j2,sha256=2CWY1i_U7RcLM-HMCkGeAlDN0doc9UcW-xVPpHzPEzw,1150
|
|
93
|
+
litestar_vite/templates/react-inertia/resources/App.css.j2,sha256=TPVP6MVH2zEgSR7enDt-AXj4LUnDIoMu7NvLoWC8xAY,1056
|
|
94
|
+
litestar_vite/templates/react-inertia/resources/main.tsx.j2,sha256=GZsP-KJ42HvI_XOHb7dcOGlhG_6EGZqzmT-45gos-a4,500
|
|
95
|
+
litestar_vite/templates/react-inertia/resources/ssr.tsx.j2,sha256=_vfiqA3_Dzma0omyjFfM7qqBDhmOz241NGZSLNsVHkE,614
|
|
96
|
+
litestar_vite/templates/react-inertia/resources/pages/Home.tsx.j2,sha256=S1XAbXKFymCt3WSC_qayE5YA2btSG7S-XwTpF-jYa1k,375
|
|
97
|
+
litestar_vite/templates/react-router/index.html.j2,sha256=M7mULWfMMDN_V7usfKw2v2Iw2-e-fuwn0-AIuOxaL6o,319
|
|
98
|
+
litestar_vite/templates/react-router/vite.config.ts.j2,sha256=4yoCesOaPcipOVV82AneKaBQHjz4rsBBD0PcKoTpDO0,811
|
|
99
|
+
litestar_vite/templates/react-router/src/App.css.j2,sha256=oKhbDtTpOdIQGI4llLwf6NPiGPx4h9FhzdvVpywlNHQ,346
|
|
100
|
+
litestar_vite/templates/react-router/src/App.tsx.j2,sha256=uUzE_BV5THUCn2xIHo2DJJP9W8ADGsCY9yGbN0PWZik,119
|
|
101
|
+
litestar_vite/templates/react-router/src/main.tsx.j2,sha256=6sAB4YrC8wyRYEFdfYegClpVvh4WT79yxwxV7HQ3NeA,227
|
|
102
|
+
litestar_vite/templates/react-tanstack/index.html.j2,sha256=M7mULWfMMDN_V7usfKw2v2Iw2-e-fuwn0-AIuOxaL6o,319
|
|
103
|
+
litestar_vite/templates/react-tanstack/openapi-ts.config.ts.j2,sha256=BdrmDeRh0dKHVyJOEBYNxNfDkivr5w_oF5o1v14HXlE,404
|
|
104
|
+
litestar_vite/templates/react-tanstack/vite.config.ts.j2,sha256=7jTZ5quvBDSnBFqQZ7-R8Of5H4TtHKUbS1ZtDLFo1lA,870
|
|
105
|
+
litestar_vite/templates/react-tanstack/src/App.css.j2,sha256=oKhbDtTpOdIQGI4llLwf6NPiGPx4h9FhzdvVpywlNHQ,346
|
|
106
|
+
litestar_vite/templates/react-tanstack/src/main.tsx.j2,sha256=aRh7VWjNojS6V-pMTddoK2HxCz51FLoP-Ojtst5emvI,569
|
|
107
|
+
litestar_vite/templates/react-tanstack/src/routeTree.gen.ts.j2,sha256=E7frsgniLGgl3jUkINs8KJJhy6wIIl0lNJA6XzIKzDg,294
|
|
108
|
+
litestar_vite/templates/react-tanstack/src/routes/__root.tsx.j2,sha256=FH2STyfqDJGmtJPdcwGpK6IQVBdBcdpWIIrrqrD4lL0,176
|
|
109
|
+
litestar_vite/templates/react-tanstack/src/routes/books.tsx.j2,sha256=VlChNKb4ggK8NRvOrshw-tzB4agdtem2Rr3YsSlcR38,186
|
|
110
|
+
litestar_vite/templates/react-tanstack/src/routes/index.tsx.j2,sha256=8aVZrx0MV5m_qYRzSGRS-kcjCjil9uWUZ4bqzFPVmsQ,181
|
|
111
|
+
litestar_vite/templates/svelte/index.html.j2,sha256=LW991plBL1vlU7tdoyJ-5aB54NztbKDCOXX-N3SK7ok,380
|
|
112
|
+
litestar_vite/templates/svelte/svelte.config.js.j2,sha256=J7deVkC7BMu73RMcfX0LJxidaQgEMPNdDunarZzpmTA,116
|
|
113
|
+
litestar_vite/templates/svelte/vite.config.ts.j2,sha256=6GqupB_dqHllrsi4Cglwc7cRIq7bCiKW8LVRBCR86Jk,824
|
|
114
|
+
litestar_vite/templates/svelte/src/App.svelte.j2,sha256=D0LAFvgqLakIM192CYOIETNNtwaMQTZ4nIOjEacSrMc,444
|
|
115
|
+
litestar_vite/templates/svelte/src/app.css.j2,sha256=danFuvZ3cTKGCS-GumMTlpxpqocQ_9rE80nDPdHOcwk,872
|
|
116
|
+
litestar_vite/templates/svelte/src/main.ts.j2,sha256=4rroqhfFf5cqn6adcC-0MvvEGTt16yCJnPmIA-Aexh0,143
|
|
117
|
+
litestar_vite/templates/svelte/src/vite-env.d.ts.j2,sha256=zJwBq4LNhm1ZaxEChjeihMPMpLEV0qpaAsMdLFmXf8E,71
|
|
118
|
+
litestar_vite/templates/svelte-inertia/index.html.j2,sha256=kEucsfi-lVPR151vAhjxyC6rdrU2-2VhegTqmK2Ptjs,448
|
|
119
|
+
litestar_vite/templates/svelte-inertia/svelte.config.js.j2,sha256=J7deVkC7BMu73RMcfX0LJxidaQgEMPNdDunarZzpmTA,116
|
|
120
|
+
litestar_vite/templates/svelte-inertia/vite.config.ts.j2,sha256=RfC11aqGLEaKxuXoCRY_hYPuggXWl739fPDtvh0Nb14,768
|
|
121
|
+
litestar_vite/templates/svelte-inertia/resources/app.css.j2,sha256=iGKzknt04zJ29-zIdThkszGnTQe-C2pdyt6zAT_3rdE,462
|
|
122
|
+
litestar_vite/templates/svelte-inertia/resources/main.ts.j2,sha256=jP5KTQRn1jQLdn-70AypUxghSDs1wRi5p60i6Nufv74,346
|
|
123
|
+
litestar_vite/templates/svelte-inertia/resources/vite-env.d.ts.j2,sha256=zJwBq4LNhm1ZaxEChjeihMPMpLEV0qpaAsMdLFmXf8E,71
|
|
124
|
+
litestar_vite/templates/svelte-inertia/resources/pages/Home.svelte.j2,sha256=QGOmxp2Y8-HxW1LXJJVDjVdeYqMVwUn0c43nrFe6Tao,740
|
|
125
|
+
litestar_vite/templates/sveltekit/openapi-ts.config.ts.j2,sha256=MpSEEQwJQ2zz-6wg_2kRsBVshoDYk1vS87i2xwEWMvQ,334
|
|
126
|
+
litestar_vite/templates/sveltekit/svelte.config.js.j2,sha256=dvoVhI4FP-PlIf4tkKuXAt-m9J8OouN-nNWew45mrFA,270
|
|
127
|
+
litestar_vite/templates/sveltekit/tsconfig.json.j2,sha256=Su4tOAJKM9eEI7rHcGxAjf_ya85j0Eigym1-2UQnnhw,363
|
|
128
|
+
litestar_vite/templates/sveltekit/vite.config.ts.j2,sha256=l3buMnky7psThMwBfHUcgv7FIiyA5Ge5_G2AQqeNep4,942
|
|
129
|
+
litestar_vite/templates/sveltekit/src/app.css.j2,sha256=pkFVaARbo97abjGZ60dCjLPi_VdFrOo7xHnqDQI_IsY,786
|
|
130
|
+
litestar_vite/templates/sveltekit/src/app.html.j2,sha256=5FiwObWMDo2rDaxGG4-5BFPGj0_lO1NKHMOEsLR1mkc,360
|
|
131
|
+
litestar_vite/templates/sveltekit/src/hooks.server.ts.j2,sha256=JeIKNDzctwlKqvbBq3yFBcACYSG6sCPh_HFmyLsPPLY,2239
|
|
132
|
+
litestar_vite/templates/sveltekit/src/routes/+layout.svelte.j2,sha256=fKXQZNrYOURUPPTmiBo9F7crDLxwudh3-tQ2g9P_5aM,202
|
|
133
|
+
litestar_vite/templates/sveltekit/src/routes/+page.svelte.j2,sha256=AXTPN9l_k1_zITu3hP_DHYE17EDChVdDA95th0AX0YU,504
|
|
134
|
+
litestar_vite/templates/vue/env.d.ts.j2,sha256=FEzWdKE_58QVLmJj7EhACflloL4h4hxr9qCr6z8xjLU,189
|
|
135
|
+
litestar_vite/templates/vue/index.html.j2,sha256=LW991plBL1vlU7tdoyJ-5aB54NztbKDCOXX-N3SK7ok,380
|
|
136
|
+
litestar_vite/templates/vue/vite.config.ts.j2,sha256=KXXZhYxRCQ8YKwElTATXbT7d1L0yUwe2_fEFKPA1YrA,804
|
|
137
|
+
litestar_vite/templates/vue/src/App.vue.j2,sha256=K8Zano4I_CZUQkCe16JIYPi2QMkpYj_576y1Lhr8Zb4,469
|
|
138
|
+
litestar_vite/templates/vue/src/main.ts.j2,sha256=Qaecy31EDctV3TooxqYgVsWbTod9n8vhfJzV1_u-LBQ,115
|
|
139
|
+
litestar_vite/templates/vue/src/style.css.j2,sha256=dynk8iHiXQgZHAnsBxMPxoyewP4P5s5ebliXVC95xVw,872
|
|
140
|
+
litestar_vite/templates/vue-inertia/env.d.ts.j2,sha256=FEzWdKE_58QVLmJj7EhACflloL4h4hxr9qCr6z8xjLU,189
|
|
141
|
+
litestar_vite/templates/vue-inertia/index.html.j2,sha256=kEucsfi-lVPR151vAhjxyC6rdrU2-2VhegTqmK2Ptjs,448
|
|
142
|
+
litestar_vite/templates/vue-inertia/package.json.j2,sha256=Th3npE3RMLob-eOvAkaA6wgurdbNWfAUB382TzRkqoo,1443
|
|
143
|
+
litestar_vite/templates/vue-inertia/vite.config.ts.j2,sha256=vWK9Ur43tY3c_g_9RPMvzRt1_pgiFU-7seYLMaoiBXY,1142
|
|
144
|
+
litestar_vite/templates/vue-inertia/resources/main.ts.j2,sha256=6wi8R1QXY_fS1WDCgup1vaDtXSswtgYY-tWWzEVIumE,526
|
|
145
|
+
litestar_vite/templates/vue-inertia/resources/ssr.ts.j2,sha256=ptxNGMv8mBDVLYzozpTZWfp2vYXLM_OmfXRDjbJD8l0,686
|
|
146
|
+
litestar_vite/templates/vue-inertia/resources/style.css.j2,sha256=iGKzknt04zJ29-zIdThkszGnTQe-C2pdyt6zAT_3rdE,462
|
|
147
|
+
litestar_vite/templates/vue-inertia/resources/pages/Home.vue.j2,sha256=wcTvXgjQZ9CxQ6aTWp95w6YS6pE1RD-BITy1lJtBmrU,702
|
|
148
|
+
litestar_vite-0.15.0rc2.dist-info/METADATA,sha256=JbvMynREO35tXobLELCOq5GzM6VkR9xXFfVVjcbmNuA,7709
|
|
149
|
+
litestar_vite-0.15.0rc2.dist-info/WHEEL,sha256=WLgqFyCfm_KASv4WHyYy0P3pM_m7J5L9k2skdKLirC8,87
|
|
150
|
+
litestar_vite-0.15.0rc2.dist-info/licenses/LICENSE,sha256=HeTiEfEgvroUXZe_xAmYHxtTBgw--mbXyZLsWDYabHc,1069
|
|
151
|
+
litestar_vite-0.15.0rc2.dist-info/RECORD,,
|
litestar_vite/template_engine.py
DELETED
|
@@ -1,103 +0,0 @@
|
|
|
1
|
-
from __future__ import annotations
|
|
2
|
-
|
|
3
|
-
from typing import TYPE_CHECKING, Any, TypeVar
|
|
4
|
-
|
|
5
|
-
import markupsafe
|
|
6
|
-
from jinja2 import TemplateNotFound as JinjaTemplateNotFound
|
|
7
|
-
from jinja2 import pass_context
|
|
8
|
-
from litestar.contrib.jinja import JinjaTemplateEngine
|
|
9
|
-
from litestar.exceptions import TemplateNotFoundException
|
|
10
|
-
from litestar.template.base import (
|
|
11
|
-
TemplateEngineProtocol,
|
|
12
|
-
)
|
|
13
|
-
|
|
14
|
-
from .loader import ViteAssetLoader
|
|
15
|
-
|
|
16
|
-
if TYPE_CHECKING:
|
|
17
|
-
from collections.abc import Callable
|
|
18
|
-
|
|
19
|
-
from jinja2 import Template as JinjaTemplate
|
|
20
|
-
from litesatr_vite.config import ViteConfig
|
|
21
|
-
from pydantic import DirectoryPath
|
|
22
|
-
|
|
23
|
-
T = TypeVar("T", bound=TemplateEngineProtocol)
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
class ViteTemplateEngine(JinjaTemplateEngine):
|
|
27
|
-
"""Jinja Template Engine with Vite Integration."""
|
|
28
|
-
|
|
29
|
-
def __init__(self, directory: DirectoryPath | list[DirectoryPath], config: ViteConfig) -> None:
|
|
30
|
-
"""Jinja2 based TemplateEngine.
|
|
31
|
-
|
|
32
|
-
Args:
|
|
33
|
-
directory: Direct path or list of directory paths from which to serve templates.
|
|
34
|
-
config: Vite config
|
|
35
|
-
"""
|
|
36
|
-
super().__init__(directory=directory)
|
|
37
|
-
self.config = config
|
|
38
|
-
self.asset_loader = ViteAssetLoader.initialize_loader(config=self.config)
|
|
39
|
-
self.engine.globals["vite_hmr_client"] = self.hmr_client
|
|
40
|
-
self.engine.globals["vite_asset"] = self.resource
|
|
41
|
-
|
|
42
|
-
def get_template(self, template_name: str) -> JinjaTemplate:
|
|
43
|
-
"""Retrieve a template by matching its name (dotted path) with files in the directory or directories provided.
|
|
44
|
-
|
|
45
|
-
Args:
|
|
46
|
-
template_name: A dotted path
|
|
47
|
-
|
|
48
|
-
Returns:
|
|
49
|
-
JinjaTemplate instance
|
|
50
|
-
|
|
51
|
-
Raises:
|
|
52
|
-
TemplateNotFoundException: if no template is found.
|
|
53
|
-
"""
|
|
54
|
-
try:
|
|
55
|
-
return self.engine.get_template(name=template_name)
|
|
56
|
-
except JinjaTemplateNotFound as exc:
|
|
57
|
-
raise TemplateNotFoundException(template_name=template_name) from exc
|
|
58
|
-
|
|
59
|
-
def register_template_callable(self, key: str, template_callable: Callable[[dict[str, Any]], Any]) -> None:
|
|
60
|
-
"""Register a callable on the template engine.
|
|
61
|
-
|
|
62
|
-
Args:
|
|
63
|
-
key: The callable key, i.e. the value to use inside the template to call the callable.
|
|
64
|
-
template_callable: A callable to register.
|
|
65
|
-
|
|
66
|
-
Returns:
|
|
67
|
-
None
|
|
68
|
-
"""
|
|
69
|
-
self.engine.globals[key] = pass_context(template_callable)
|
|
70
|
-
|
|
71
|
-
def hmr_client(self) -> markupsafe.Markup:
|
|
72
|
-
"""Generate the script tag for the Vite WS client for HMR.
|
|
73
|
-
|
|
74
|
-
Only used when hot module reloading is enabled, in production this method returns an empty string.
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
Returns:
|
|
78
|
-
str: The script tag or an empty string.
|
|
79
|
-
"""
|
|
80
|
-
tags = [self.asset_loader.generate_react_hmr_tags()]
|
|
81
|
-
tags.append(self.asset_loader.generate_ws_client_tags())
|
|
82
|
-
return markupsafe.Markup("".join(tags))
|
|
83
|
-
|
|
84
|
-
def resource(self, path: str, scripts_attrs: dict[str, str] | None = None) -> markupsafe.Markup:
|
|
85
|
-
"""Generate all assets include tags for the file in argument.
|
|
86
|
-
|
|
87
|
-
Generates all scripts tags for this file and all its dependencies
|
|
88
|
-
(JS and CSS) by reading the manifest file (for production only).
|
|
89
|
-
In development Vite imports all dependencies by itself.
|
|
90
|
-
Place this tag in <head> section of your page
|
|
91
|
-
(this function marks automatically <script> as "async" and "defer").
|
|
92
|
-
|
|
93
|
-
Arguments:
|
|
94
|
-
path: Path to a Vite asset to include.
|
|
95
|
-
scripts_attrs: script attributes
|
|
96
|
-
|
|
97
|
-
Keyword Arguments:
|
|
98
|
-
scripts_attrs {Optional[Dict[str, str]]}: Override attributes added to scripts tags. (default: {None})
|
|
99
|
-
|
|
100
|
-
Returns:
|
|
101
|
-
str: All tags to import this asset in your HTML page.
|
|
102
|
-
"""
|
|
103
|
-
return markupsafe.Markup(self.asset_loader.generate_asset_tags(path, scripts_attrs=scripts_attrs))
|
|
@@ -1,68 +0,0 @@
|
|
|
1
|
-
Metadata-Version: 2.1
|
|
2
|
-
Name: litestar-vite
|
|
3
|
-
Version: 0.1.1
|
|
4
|
-
Summary: Vite plugin for Litestar
|
|
5
|
-
Project-URL: Changelog, https://cofin.github.io/litesatr-vite/latest/changelog
|
|
6
|
-
Project-URL: Discord, https://discord.gg/X3FJqy8d2j
|
|
7
|
-
Project-URL: Documentation, https://cofin.github.io/litesatr-vite/latest/
|
|
8
|
-
Project-URL: Homepage, https://cofin.github.io/litesatr-vite/latest/
|
|
9
|
-
Project-URL: Issue, https://github.com/cofin/litestar-vite/issues/
|
|
10
|
-
Project-URL: Source, https://github.com/cofin/litestar-vite
|
|
11
|
-
Author-email: Cody Fincher <cody.fincher@gmail.com>
|
|
12
|
-
License: MIT
|
|
13
|
-
License-File: LICENSE
|
|
14
|
-
Keywords: litestar,vite
|
|
15
|
-
Classifier: Development Status :: 3 - Alpha
|
|
16
|
-
Classifier: Environment :: Web Environment
|
|
17
|
-
Classifier: Intended Audience :: Developers
|
|
18
|
-
Classifier: Intended Audience :: System Administrators
|
|
19
|
-
Classifier: License :: OSI Approved :: MIT License
|
|
20
|
-
Classifier: Natural Language :: English
|
|
21
|
-
Classifier: Operating System :: OS Independent
|
|
22
|
-
Classifier: Programming Language :: Python
|
|
23
|
-
Classifier: Programming Language :: Python :: 3.8
|
|
24
|
-
Classifier: Programming Language :: Python :: 3.9
|
|
25
|
-
Classifier: Programming Language :: Python :: 3.10
|
|
26
|
-
Classifier: Programming Language :: Python :: 3.11
|
|
27
|
-
Classifier: Programming Language :: Python :: 3.12
|
|
28
|
-
Classifier: Topic :: Database
|
|
29
|
-
Classifier: Topic :: Database :: Database Engines/Servers
|
|
30
|
-
Classifier: Topic :: Software Development
|
|
31
|
-
Classifier: Typing :: Typed
|
|
32
|
-
Requires-Python: >=3.8
|
|
33
|
-
Requires-Dist: litestar[cli,jinja]>=2.0.1
|
|
34
|
-
Description-Content-Type: text/markdown
|
|
35
|
-
|
|
36
|
-
# Litestar Vite
|
|
37
|
-
|
|
38
|
-
> [!IMPORTANT]
|
|
39
|
-
> This plugin currently contains minimal features and is a work-in-progress
|
|
40
|
-
|
|
41
|
-
## Installation
|
|
42
|
-
|
|
43
|
-
```shell
|
|
44
|
-
pip install litestar-vite
|
|
45
|
-
```
|
|
46
|
-
|
|
47
|
-
## Usage
|
|
48
|
-
|
|
49
|
-
Here is a basic application that demonstrates how to use the plugin.
|
|
50
|
-
|
|
51
|
-
```python
|
|
52
|
-
from __future__ import annotations
|
|
53
|
-
|
|
54
|
-
from litestar import Litestar
|
|
55
|
-
from litestar_vite import ViteConfig, VitePlugin
|
|
56
|
-
|
|
57
|
-
vite = VitePlugin(
|
|
58
|
-
config=ViteConfig(
|
|
59
|
-
static_dir="./local_static_dir",
|
|
60
|
-
templates_dir="./path_to_jinja_templates",
|
|
61
|
-
# Should be False when in production
|
|
62
|
-
hot_reload=True, # Websocket HMR asset reloading is enabled when true.
|
|
63
|
-
port=3005,
|
|
64
|
-
),
|
|
65
|
-
)
|
|
66
|
-
app = Litestar(plugins=[vite])
|
|
67
|
-
|
|
68
|
-
```
|
|
@@ -1,11 +0,0 @@
|
|
|
1
|
-
litestar_vite/__init__.py,sha256=9X3i67Q8DJN2lQYAMa9NSPTZGzHASGn8X8yeWJqBvWg,357
|
|
2
|
-
litestar_vite/__metadata__.py,sha256=Eml1c9xezV-GSodmysksrT8jPWqE__x0ENO1wM5g6q0,319
|
|
3
|
-
litestar_vite/cli.py,sha256=8MDS91THfyyWnI_zxANI3rdnGooDsHfVW1cKxpX5eNo,691
|
|
4
|
-
litestar_vite/config.py,sha256=yWGY-Fdbe2OLjfGR65bPL2YJ_BxUJ_dmj_2KVz7GU_c,3303
|
|
5
|
-
litestar_vite/loader.py,sha256=mHvvDD_1ES7E6Ig8AntWrMZTxCPDKp9zmkEUoarzb7Q,6580
|
|
6
|
-
litestar_vite/plugin.py,sha256=2DlfFJJk7mVdKOeqbyEarJ5F-1TC9NKK5L-Ljyi956Q,1304
|
|
7
|
-
litestar_vite/template_engine.py,sha256=h-vBASqyYDeURzvJPpwrIIvoVyFkK2kqcSMAglwlI-U,3833
|
|
8
|
-
litestar_vite-0.1.1.dist-info/METADATA,sha256=hElk8qArZ_hC8OfFA3gKdCHNOC-ywGP0SfOOUQvm0HE,2181
|
|
9
|
-
litestar_vite-0.1.1.dist-info/WHEEL,sha256=9QBuHhg6FNW7lppboF2vKVbCGTVzsFykgRQjjlajrhA,87
|
|
10
|
-
litestar_vite-0.1.1.dist-info/licenses/LICENSE,sha256=HeTiEfEgvroUXZe_xAmYHxtTBgw--mbXyZLsWDYabHc,1069
|
|
11
|
-
litestar_vite-0.1.1.dist-info/RECORD,,
|
|
File without changes
|