Skip to content

Releases: litestar-org/litestar-vite

v0.12.0

23 Dec 05:40
Compare
Choose a tag to compare

What's Changed

  • feat: adds lazy support for inertia by @cofin in #61

** Note ** This adds experimental support for deferring the rendering of props until the request is rendered. This allows you to use the partial data component of inertia to optional request/refresh data.

The function is titled lazy and accepts 2 parameters: A string based "key" and the value or function (sync or async) to defer:

async def basic_example_of_lazy_rendering() -> None:
    def simulated_expensive_sync_function() -> str:
        sleep(0.5)
        return "callable_result"

    async def simulated_expensive_async_function() -> str:
        await asyncio.sleep(0.5)
        return "async_result"

    lazy_future_for_sync_method = lazy("test_prop_1", simulated_expensive_sync_function)
    assert lazy_future_for_sync_method.render(portal) == "callable_result"
    
    lazy_future_for_async_method = lazy("test_prop_2", simulated_expensive_async_function)
    assert lazy_future_for_async_method.render(portal) == "async_result"

Full Changelog: v0.11.1...v0.12.0

v0.11.1

09 Dec 03:00
Compare
Choose a tag to compare

This is a minor change to use the subprocess directly instead of through a thread.

Full Changelog: v0.11.0...v0.11.1

v0.11.0

09 Dec 02:44
Compare
Choose a tag to compare

What's Changed

  • feat: improved process management by @cofin in #59

Full Changelog: v0.10.0...v0.11.0

v0.10.0

08 Dec 01:09
Compare
Choose a tag to compare

This is a breaking change.

This change removes the customized template config and prefers to patch the built in one.

Instead of:

vite = VitePlugin(config=ViteConfig(template_dir='templates/'))
app = Litestar(plugins=[vite], route_handlers=[WebController])

use:

template_config = TemplateConfig(engine=JinjaTemplateEngine(directory='templates/'))
vite = VitePlugin(config=ViteConfig())
app = Litestar(plugins=[vite], template_config=template_config, route_handlers=[WebController])

What's Changed

  • feat(templates)!: remove custom JinjaTemplateEngine by @cofin in #58

Full Changelog: v0.9.0...v0.10.0

v0.9.0

07 Dec 00:05
Compare
Choose a tag to compare

What's Changed

  • chore(build): reformatted Makefile by @cofin in #56
  • feat(vite): auto-detect SPA index.html by @cofin in #57

Full Changelog: v0.8.3...v0.9.0

v0.8.3

06 Dec 18:36
Compare
Choose a tag to compare

Sorry for the back-to-back releases. There were still a few publishing issues remaining in the build pipeline for the NPM package.

Full Changelog: v0.8.2...v0.8.3

v0.8.2

06 Dec 18:26
Compare
Choose a tag to compare

What's Changed

  • fix: modified --root-path option behavior when CLI init by @maintain0404 in #48

New Contributors

Full Changelog: v0.8.1...v0.8.2

v0.8.1

01 Dec 22:40
Compare
Choose a tag to compare

This is a minor release that corrects an issue with the generated wheel file.

The litestar_vite module is now correctly included with the wheel contents.

Full Changelog: v0.8.0...v0.8.1

v0.8.0

01 Dec 05:36
Compare
Choose a tag to compare

What's Changed

  • feat: adds 404 redirect option by @cofin in #46

Full Changelog: v0.7.1...v0.8.0

v0.7.1

30 Nov 22:03
Compare
Choose a tag to compare

What's Changed

  • fix(docs): Update build_docs.py by @Alc-Alc in #54
  • chore(docs): updated release process by @cofin in #55

New Contributors

Full Changelog: v0.7.0...v0.7.1